You're running Zen Cart v1.3.8a (the last version where the general.php module contained a date_diff function) on a PHP version at or above 5.3 (where the date_diff function was introduced).
There are a couple of files that can be edited so that you can continue to limp along while you're planning your upgrade to Zen Cart v1.5.4:
1. Edit your admin's (and be sure to rename your admin folder) /includes/functions/general.php, finding:
and changing that toCode:function date_diff($date1, $date2) {
2. Edit /YOUR_ADMIN/includes/header.php, finding:Code:function zen_date_diff($date1, $date2) {
and changing that toCode:$zc_days_to_expire = date_diff($zc_current_date, $zc_welcome_check->fields['coupon_expire_date']);
3. Edit /YOUR_ADMIN/includes/modules/orders_download, finding 2 occurrences (1 within a commented line) of date_diff and changing both to zen_date_diff.Code:$zc_days_to_expire = zen_date_diff($zc_current_date, $zc_welcome_check->fields['coupon_expire_date']);
4. Edit /YOUR_ADMIN/orders.php, finding 2 occurrences of date_diff and changing both to zen_date_diff.


Reply With Quote
