Support the ongoing development of Laravel.io →
2 years ago
Last updated 3 months 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 2 years ago.
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!

Cloudways

Your banner here too?

Morten Morten kh4zy Joined 26 Jan 2020

Moderators

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

Your logo here?

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

© 2022 Laravel.io - All rights reserved.