Storing dates (cDatePublic) in European format (dd/mm/yy)

Permalink
Hi all

I'm building a 1-page editing form for the Dashboard and I want to be able to specify the Public Date for a page. I've created the front-end interface, including a date picker using datetime(). This works fine, but the dates aren't stored in the database.

I've changed the date format in jquery.ui to dd/mm/yy, and I've added this constant to site.php:

define('DATE_APP_GENERIC_MDY', 'd/m/Y');

but they don't work. I can only assume that the translate() method isn't doing its job properly, but when I had a look at it my brain melted.

Any thoughts?

melat0nin
 
cjramki replied on at Permalink Reply
cjramki
I know this is old post... but the others reference i replied...
Add this code in your site.php
define('DATE_APP_GENERIC_MDY', 'd.m.Y');
define('DATE_APP_GENERIC_MDYT_FULL', 'd.m.Y H:i:s');
define('DATE_APP_GENERIC_MDYT', 'd.m.Y H:i:s');
define('DATE_APP_DATE_PICKER', 'dd.mm.yy');