On December 29, 2020 . By CodimTh Category: Web Laravel Call to a member function addDays() on string on Laravel You can use Carbon to convert string into a date: $date = Carbon::parse($request->date)->addDays(3); Then you can also format the date as you expect $date->format('Y-m-d'); Tags : Laravel Laravel tutoriel Tips Laravel Previous PostHow to add a menu item to the drupal toolbarNext PostLaravel - Validate the password reset token before showing the reset form Comments Add new comment Your name Subject Comment About text formats Restricted HTML Leave this field blank
Comments