Datepicker format is
MM/DD/YYYY
and Database format is:
Y-m-d
how to format your date to the correct for you db. you can use
Carbon
:
use Carbon\Carbon;

 start_date = Carbon::parse($request->start_date)->format('Y-m-d');
use carbon function in laravel view(Blade template)
  $start_date = \Carbon\Carbon::parse( $item->start_date)->format('m/d/Y');
by გიორგი ბაკაშვილი
4 years ago
Laravel
Date
3
Pro tip: use ```triple backticks around text``` to write in code fences
0
Valeri Tandilashvili 4 years ago
Good job, but can we try to change datepicker to put date with our desired format ?
REPLY