Formatting a MySQL timestamp field
Posted: Tue Jan 17, 2012 1:51 pm
I've just started my first project using Xataface, and so far I'm very impressed!
I have a quick question about formatting dates. I'm sure this should be possible and easy, but I haven't found the correct way to do it even after some rather extensive searching.
If I use a DATETIME field, dates appear in list view like "2012-01-17 13:04:03". But if I use a TIMESTAMP field, which I need to do, they appear like "20120117130403". I need to have the time display formatting that is applied to DATETIME fields also apply to the TIMESTAMP field.
I tried using date_format in fields.ini with no luck.
Is there a correct way to do this?
Thanks!
I have a quick question about formatting dates. I'm sure this should be possible and easy, but I haven't found the correct way to do it even after some rather extensive searching.
If I use a DATETIME field, dates appear in list view like "2012-01-17 13:04:03". But if I use a TIMESTAMP field, which I need to do, they appear like "20120117130403". I need to have the time display formatting that is applied to DATETIME fields also apply to the TIMESTAMP field.
I tried using date_format in fields.ini with no luck.
Is there a correct way to do this?
Thanks!