cr41g Posted November 8, 2008 Share Posted November 8, 2008 When my customers are entering their details I want them to input the date in the format above but this is currently set as an error. I've tried changing a few lines of which I thought may do it but I am obviously wrong it still dosen't work. Can anyone point me in the right direction? Link to comment Share on other sites More sharing options...
germ Posted November 8, 2008 Share Posted November 8, 2008 Maybe some help here: UK Your Shop If I suggest you edit any file(s) make a backup first - I'm not perfect and neither are you. "Given enough impetus a parallelogramatically shaped projectile can egress a circular orifice." - Me - "Headers already sent" - The definitive help "Cannot redeclare ..." - How to find/fix it SSL Implementation Help Like this post? "Like" it again over there > Link to comment Share on other sites More sharing options...
Guest Posted November 8, 2008 Share Posted November 8, 2008 Alternatively you could use this contribution UK Based osCommerce It's supposed to be done pre install but it is possible to use after install especially if your careful and examine the sql carefully. Link to comment Share on other sites More sharing options...
Hotclutch Posted November 8, 2008 Share Posted November 8, 2008 OR THIS Go to catalog\includes\languages\english.php find @setlocale(LC_TIME, 'en_US.ISO_8859-1'); define('DATE_FORMAT_SHORT', '%m/%d/%Y'); // this is used for strftime() define('DATE_FORMAT_LONG', '%A %d %B, %Y'); // this is used for strftime() define('DATE_FORMAT', 'm/d/Y'); // this is used for date() define('DATE_TIME_FORMAT', DATE_FORMAT_SHORT . ' %H:%M:%S'); //// // Return date in raw format // $date should be in format mm/dd/yyyy // raw date is in format YYYYMMDD, or DDMMYYYY function tep_date_raw($date, $reverse = false) { if ($reverse) { return substr($date, 3, 2) . substr($date, 0, 2) . substr($date, 6, 4); } else { return substr($date, 6, 4) . substr($date, 0, 2) . substr($date, 3, 2); } } and replace with @setlocale(LC_TIME, 'en_US.ISO_8859-1'); define('DATE_FORMAT_SHORT', '%d/%m/%Y'); // this is used for strftime() define('DATE_FORMAT_LONG', '%A %d %B, %Y'); // this is used for strftime() define('DATE_FORMAT', 'd/m/Y'); // this is used for date() define('DATE_TIME_FORMAT', DATE_FORMAT_SHORT . ' %H:%M:%S'); //// // Return date in raw format // $date should be in format dd/mm/yyyy // raw date is in format YYYYMMDD, or DDMMYYYY function tep_date_raw($date, $reverse = false) { if ($reverse) { return substr($date, 0, 2) . substr($date, 3, 2) . substr($date, 6, 4); } else { return substr($date, 6, 4) . substr($date, 3, 2) . substr($date, 0, 2); } } Also change the following definitions CODE define('ENTRY_DATE_OF_BIRTH_ERROR', 'Your Date of Birth must be in this format: MM/DD/YYYY (eg 05/21/1970)'); to CODE define('ENTRY_DATE_OF_BIRTH_ERROR', 'Your Date of Birth must be in this format: DD/MM/YYYY (eg 21/05/1970)'); CODE define('ENTRY_DATE_OF_BIRTH_TEXT', '* (eg. 05/21/1970)'); to CODE define('ENTRY_DATE_OF_BIRTH_TEXT', '* (eg. 21/05/1970)'); CODE define('DOB_FORMAT_STRING', 'mm/dd/yyyy'); to CODE define('DOB_FORMAT_STRING', 'dd/mm/yyyy'); You might want to do the same on the admin side. Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.