Support the ongoing development of Laravel.io →
posted 4 years ago
Last updated 2 years ago.
0

First of all the date shouldn't be a 'string' type. However if that works for you fine.

You could put this in your model.

         protected $dateFormat = 'Y-d-m';

Or whatever the format you're using.

0

Ive tried protected $dateFormat = 'd-m-Y H:i:s'; But it gave me a mysql error. Seems like mysql cant like that format then :S

Last updated 4 years ago.
0

Check this out I think this is exactly what you need.

  https://laracasts.com/discuss/channels/general-discussion/how-to-carbonparse-in-ddmmyyyy-format
0

Through our experts, we offer all kinds of Psychology Writing Services and Psychology Coursework Writing Help to suit the need of every student when they are given any Psychology Research Paper Writing Services. https://researchpapers247.com/psychology-writing-services/

0

When students seek our Psychology Writing Services from us, they are assured to receive Custom Psychology Writing Services that meets all their writing needs and Online Psychology Writing Services one that has been written following all the instructions. https://www.meldaresearch.com/psychology-writing-services/

0

Sign in to participate in this thread!

Eventy

Your banner here too?

Morten kh4zy Joined 26 Jan 2020

Moderators

We'd like to thank these amazing companies for supporting us

Your logo here?

Laravel.io

The Laravel portal for problem solving, knowledge sharing and community building.

© 2024 Laravel.io - All rights reserved.