Wedding Invitation
Nelze vybrat více než 25 témat Téma musí začínat písmenem nebo číslem, může obsahovat pomlčky („-“) a může být dlouhé až 35 znaků.

rsvp-digital-card.blade.php 4.7KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117
  1. <!DOCTYPE html>
  2. <html lang="en">
  3. <head>
  4. <meta charset="UTF-8">
  5. <meta name="viewport" content="width=device-width, initial-scale=1.0">
  6. <meta http-equiv="X-UA-Compatible" content="ie=edge">
  7. <meta name="color-scheme" content="light only">
  8. <title>{{config('app.name')}}</title>
  9. <link rel="preconnect" href="https://fonts.bunny.net">
  10. <link href="https://fonts.bunny.net/css?family=figtree:400,600&display=swap" rel="stylesheet" />
  11. <link href="https://cdn.jsdelivr.net/npm/daisyui@4.12.10/dist/full.min.css" rel="stylesheet" type="text/css" />
  12. <meta name="csrf-token" content="{{ csrf_token() }}">
  13. @vite(['resources/css/app.css'])
  14. </head>
  15. <body class="antialiased font-serif">
  16. <audio id="player" autoplay="autoplay" loop>
  17. <source src="{{asset('assets/background-musicv2.mp3')}}" type="audio/mp3">
  18. </audio>
  19. <script>
  20. document.addEventListener('DOMContentLoaded', (event) => {
  21. document.documentElement.classList.add('light-mode');
  22. });
  23. </script>
  24. <div class="section bg-babyblue h-screen w-screen flex justify-center items-center">
  25. <div class="flex flex-col gap-3 w-4/5 z-10">
  26. <div class="flex justify-center">
  27. <p class="font-normal text-base text-navbarcolor uppercase">MAJLIS PERKAHWINAN ALIFF & AYUNA</p>
  28. </div>
  29. <div class="flex justify-center pt-8 pb-6">
  30. <img src="{{ asset('assets/logosmallest.png') }}" alt="Logo">
  31. </div>
  32. <div class="flex justify-center">
  33. <p class="font-normal text-2xl text-navbarcolor uppercase">RSVP</p>
  34. </div>
  35. <div class="flex justify-center">
  36. <form id="RSVPForm" class="flex flex-col gap-3">
  37. @csrf
  38. <label class="input input-sm input-bordered flex items-center gap-2">
  39. Name :
  40. <input type="text" name="name" class="grow"/>
  41. </label>
  42. <label class="input input-sm input-bordered flex items-center gap-2">
  43. Bilangan :
  44. <input type="number" name="member" class="grow"/>
  45. </label>
  46. <label class="input input-sm input-bordered flex items-center gap-2">
  47. No. Tel :
  48. <input type="number" name="phone" class="grow"/>
  49. </label>
  50. <button id="submitForm" class="bg-babybluedark rounded-lg py-2 text-navbarcolor">Hantar</button>
  51. </form>
  52. </div>
  53. <div class="flex justify-center pt-2">
  54. <a onclick="contact.showModal()" class="bg-white rounded-full py-3 px-4 text-navbarcolor">
  55. <i class="fa-solid fa-phone"></i>
  56. </a>
  57. @include('modals.contact-modal')
  58. </div>
  59. </div>
  60. <img src="{{asset('assets/flower-left.png')}}" alt="" class="fixed -left-3/4 top-28">
  61. <img src="{{asset('assets/flower-right.png')}}" alt="" class="fixed -right-3/4 top-8">
  62. </div>
  63. <script src="https://code.jquery.com/jquery-3.6.0.min.js"></script>
  64. <script>
  65. $(document).ready(function() {
  66. $('#submitForm').click(function(e) {
  67. e.preventDefault();
  68. var formData = $('#RSVPForm').serialize();
  69. $.ajax({
  70. url: '{{ route('rsvp.save') }}',
  71. type: 'POST',
  72. data: formData,
  73. success: function(response) {
  74. if ('{{ session('success') }}') {
  75. showSuccessMessage('{{ session('success') }}');
  76. }
  77. $('#RSVPForm')[0].reset();
  78. },
  79. error: function(xhr, status, error) {
  80. console.error('Error submitting form:', error);
  81. }
  82. });
  83. });
  84. function showSuccessMessage(message) {
  85. // Create a dynamic success message element
  86. var successAlert = $('<div class="bg-green-100 border border-green-400 text-green-700 px-4 py-3 rounded relative" role="alert">' +
  87. '<span class="block sm:inline">' + message + '</span>' +
  88. '</div>');
  89. // Append the message to a suitable container in your HTML (e.g., modal, form, or body)
  90. $('#alert-success').append(successAlert);
  91. // Automatically remove the message after 3 seconds
  92. setTimeout(function() {
  93. successAlert.fadeOut('slow', function() {
  94. $(this).remove();
  95. });
  96. }, 3000); // 3 seconds
  97. }
  98. });
  99. </script>
  100. </body>
  101. </html>