Skorpius

Untitled

Oct 15th, 2024
137
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 2.15 KB | Source Code | 0 0
  1. // app.blade.php layout - file location - Resources/views/layouts/
  2.  
  3. <!DOCTYPE html>
  4. <html lang="{{ str_replace('_', '-', app()->getLocale()) }}">
  5. <head>
  6.     <meta charset="utf-8">
  7.     <meta name="viewport" content="width=device-width, initial-scale=1">
  8.     <meta name="csrf-token" content="{{ csrf_token() }}">
  9.  
  10.     <title>@yield('title', config('app.name', 'Laravel'))</title> <!-- Update this line -->
  11.     <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/[email protected]/font/bootstrap-icons.css">
  12.  
  13.     <!-- Fonts -->
  14.     <link rel="preconnect" href="https://fonts.bunny.net">
  15.     <link href="https://fonts.bunny.net/css?family=figtree:400,500,600&display=swap" rel="stylesheet" />
  16.  
  17.     <!-- Scripts -->
  18.     @vite(['resources/css/app.css', 'resources/js/app.js'])
  19.  
  20.     <style>
  21.         /* Ensure the body and html take the full height */
  22.         html, body {
  23.             height: 100%;
  24.             margin: 0; /* Remove default margin */
  25.         }
  26.        
  27.         /* Flexbox layout for the entire page */
  28.         .min-h-screen {
  29.             display: flex;
  30.             flex-direction: column; /* Vertical alignment */
  31.             min-height: 100vh; /* Ensure the container fills the viewport */
  32.         }
  33.  
  34.         main {
  35.             flex: 1; /* Allow main to grow and fill space */
  36.         }
  37.     </style>
  38. </head>
  39. <body class="font-sans antialiased">
  40.     <div class="min-h-screen bg-gray-100 dark:bg-gray-900">
  41.         @include('layouts.navigation')
  42.  
  43.         <!-- Page Heading -->
  44.         @isset($header)
  45.             <header class="bg-white dark:bg-gray-800 shadow">
  46.                 <div class="max-w-7xl mx-auto py-6 px-4 sm:px-6 lg:px-8">
  47.                     {{ $header }}
  48.                 </div>
  49.             </header>
  50.         @endisset
  51.  
  52.         <!-- Page Content -->
  53.         <main>
  54.             @yield('content') <!-- Ensure this line is present -->
  55.         </main>
  56.  
  57.         <!-- Include the footer here -->
  58.         @include('layouts.footer') <!-- Footer will appear at the bottom -->
  59.     </div>
  60.     <script>
  61.         var recaptchaSiteKey = "{{ env('RECAPTCHA_SITE_KEY') }}";
  62.     </script>
  63.    
  64.    
  65.  
  66. </body>
  67. </html>
  68.  
Advertisement
Add Comment
Please, Sign In to add comment