Advertisement
MrGoatsy

Untitled

Feb 26th, 2021
1,104
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 1.10 KB | None | 0 0
  1. @extends('layouts.app')
  2.  
  3. @section('content')
  4.     <div class="flex justify-center">
  5.         <div class="w-8/12 bg-gray-100 p-6 m-6">
  6.             @auth
  7.                 <form action="{{ route('posts') }}" method="POST">
  8.                     @csrf
  9.                     <div class="mb-4">
  10.                         <label for="body" class="sr-only">Body</label>
  11.                         <textarea type="text" name="bodya" class="border-2 w-full p-4" placeholder="Post something cool...">{{ old('body') }}</textarea>
  12.                        
  13.                     @error('body')
  14.                         <div class="text-red-500 mt-2 text-sm">
  15.                             {{ $message }}
  16.                         </div>
  17.                     @enderror
  18.                     </div>
  19.                     <div class="mb-4">
  20.                         <button type="submit" class="bg-blue-500 hover:bg-blue-700 text-white font-bold py-2 px-4 rounded">
  21.                             Submit
  22.                         </button>
  23.                     </div>
  24.                 </form>
  25.             @endauth
  26.         </div>
  27.     </div>
  28. @endsection
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement