Hi,
I notice that metadot put the following time stamp for all the date format (including in table, it will sort based on european date format, not the other. For example, i added a news item and it entered the following date 2002-05-06
I couldn't find the format anywhere... can you please help me resolve this problem?
Thanks
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
yyyy-mm-dd is the default MySQL dateformat. To change it you simply find where it pulls the date in the initialization scripts of the gizmos and simply replace the fieldname with:
DATE_FORMAT(fieldname,"%m-%d-%Y")
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Hi,
I notice that metadot put the following time stamp for all the date format (including in table, it will sort based on european date format, not the other. For example, i added a news item and it entered the following date 2002-05-06
I couldn't find the format anywhere... can you please help me resolve this problem?
Thanks
yyyy-mm-dd is the default MySQL dateformat. To change it you simply find where it pulls the date in the initialization scripts of the gizmos and simply replace the fieldname with:
DATE_FORMAT(fieldname,"%m-%d-%Y")
I looked in Table.pm gizmo, but did not find where I would change it. I found in Category.pm and changed to
date_format(showfrom, '%Y%m%d')
from
date_format(showfrom, '%m%d%Y')
but Table created in Metadot still showing yy-mm-dd but in the discussion the format is what I want.
Also did that in Gizmo.pm
From date_format(showfrom,'%Y-%m-%d'),
To
date_format(showfrom,'%m-%d-%Y'),
but still Table sorting as YY-mm-dd.