Zen Cart Logo
Forums / All Other Contributions/Addons / Shipstation Function strftime() is deprecated in 1.58

Shipstation Function strftime() is deprecated in 1.58

Views: 1,320

Results 1 to 6 of 6
29 Oct 2022, 12:03 AM
#1
gtgeorge avatar

gtgeorge

New Zenner

Join Date:
Mar 2005
Posts:
53
Plugin Contributions:
0

Shipstation Function strftime() is deprecated in 1.58

Zen Cart 1.5.8 upgraded from 1.5.7d
PHP Version: 8.1.10 (Zend: 4.1.10)
MySQL 5.7.30
Plugins:
one_page_checkout-2.4.3, edit_orders-4.6.2, mailchimp, Google reCaptcha v3.4

Upgraded to 1.5.8 and getting this error when ShipStation calls out for an update.

[28-Oct-2022 19:43:15 America/New_York] Request URI: /shipstation_zc.php?SS-UserName=MyUsername&SS-Password=MyPasswordaction=export&start_date=10%2f27%2f2022+23%3a55&end_date=10%2f29%2f2022+16%3a43&page=1, IP address: 34.200.10.239
#0 /shipstation_zc.php(105): zen_debug_error_handler()
#1 /shipstation_zc.php(176): zen_datetime_short2()
--> PHP Deprecated: Function strftime() is deprecated in /shipstation_zc.php on line 105.
29 Oct 2022, 12:09 AM
#2
gtgeorge avatar

gtgeorge

New Zenner

Join Date:
Mar 2005
Posts:
53
Plugin Contributions:
0

Re: Shipstation Function strftime() is deprecated in 1.58

gtgeorge:

Zen Cart 1.5.8 upgraded from 1.5.7d
PHP Version: 8.1.10 (Zend: 4.1.10)
MySQL 5.7.30
Plugins:
one_page_checkout-2.4.3, edit_orders-4.6.2, mailchimp, Google reCaptcha v3.4

Upgraded to 1.5.8 and getting this error when ShipStation calls out for an update.

[28-Oct-2022 19:43:15 America/New_York] Request URI: /shipstation_zc.php?SS-UserName=MyUsername&SS-Password=MyPasswordaction=export&start_date=10%2f27%2f2022+23%3a55&end_date=10%2f29%2f2022+16%3a43&page=1, IP address: 34.200.10.239
#0 /shipstation_zc.php(105): zen_debug_error_handler()
#1 /shipstation_zc.php(176): zen_datetime_short2()
--> PHP Deprecated: Function strftime() is deprecated in /shipstation_zc.php on line 105.


As well as the rest:

[28-Oct-2022 19:43:15 America/New_York] Request URI: /shipstation_zc.php?SS-UserName=MyUsername&SS-Password=MyPasswordaction=export&start_date=10%2f27%2f2022+23%3a55&end_date=10%2f29%2f2022+16%3a43&page=1, IP address: 34.200.10.239
#0 /shipstation_zc.php(130): zen_debug_error_handler()
--> PHP Warning: Undefined array key "customers_default_address_id" in /shipstation_zc.php on line 130.

[28-Oct-2022 19:43:15 America/New_York] Request URI: /shipstation_zc.php?SS-UserName=MyUsername&SS-Password=MyPasswordaction=export&start_date=10%2f27%2f2022+23%3a55&end_date=10%2f29%2f2022+16%3a43&page=1, IP address: 34.200.10.239
#0 /shipstation_zc.php(228): zen_debug_error_handler()
--> PHP Warning: Undefined array key "zone_code" in /shipstation_zc.php on line 228.

[28-Oct-2022 19:43:15 America/New_York] Request URI: /shipstation_zc.php?SS-UserName=MyUsername&SS-Password=MyPasswordaction=export&start_date=10%2f27%2f2022+23%3a55&end_date=10%2f29%2f2022+16%3a43&page=1, IP address: 34.200.10.239
#0 /shipstation_zc.php(250): zen_debug_error_handler()
--> PHP Warning: Undefined array key "zone_code" in /shipstation_zc.php on line 250.

[28-Oct-2022 19:43:15 America/New_York] Request URI: /shipstation_zc.php?SS-UserName=MyUsername&SS-Password=MyPasswordaction=export&start_date=10%2f27%2f2022+23%3a55&end_date=10%2f29%2f2022+16%3a43&page=1, IP address: 34.200.10.239
#0 /shipstation_zc.php(130): zen_debug_error_handler()
--> PHP Warning: Undefined array key "customers_default_address_id" in /shipstation_zc.php on line 130.

[28-Oct-2022 19:43:15 America/New_York] Request URI: /shipstation_zc.php?SS-UserName=MyUsername&SS-Password=MyPasswordaction=export&start_date=10%2f27%2f2022+23%3a55&end_date=10%2f29%2f2022+16%3a43&page=1, IP address: 34.200.10.239
#0 /shipstation_zc.php(228): zen_debug_error_handler()
--> PHP Warning: Undefined array key "zone_code" in /shipstation_zc.php on line 228.

[28-Oct-2022 19:43:15 America/New_York] Request URI: /shipstation_zc.php?SS-UserName=MyUsername&SS-Password=MyPasswordaction=export&start_date=10%2f27%2f2022+23%3a55&end_date=10%2f29%2f2022+16%3a43&page=1, IP address: 34.200.10.239
#0 /shipstation_zc.php(250): zen_debug_error_handler()
--> PHP Warning: Undefined array key "zone_code" in /shipstation_zc.php on line 250.

[28-Oct-2022 19:43:15 America/New_York] Request URI: /shipstation_zc.php?SS-UserName=MyUsername&SS-Password=MyPasswordaction=export&start_date=10%2f27%2f2022+23%3a55&end_date=10%2f29%2f2022+16%3a43&page=1, IP address: 34.200.10.239
#0 /shipstation_zc.php(130): zen_debug_error_handler()
--> PHP Warning: Undefined array key "customers_default_address_id" in /shipstation_zc.php on line 130.

14 Feb 2024, 9:04 PM
#4
getaped avatar

getaped

New Zenner

Join Date:
Jul 2013
Posts:
9
Plugin Contributions:
0

Re: Shipstation Function strftime() is deprecated in 1.58

anyone know how to fix this?

i've added

global $zcDate;
return $zcDate->output(DATE_FORMAT_LONG, mktime($hour, $minute, $second, $month, $day, $year));

but get this error now: PHP Fatal error: Uncaught Error: Call to a member function output() on null on the return line

15 Feb 2024, 2:10 AM
#5
lat9 avatar

lat9

Administrator

Join Date:
Sep 2009
Location:
Stuart, FL
Posts:
14,085
Plugin Contributions:
56

Re: Shipstation Function strftime() is deprecated in 1.58

FWIW, I replaced the return statement in the zen_datetime_short2 function with

    return date('m/d/Y H:i:s', mktime($hour, $minute, $second, $month, $day, $year));  //- zc158 upgrade, replace deprecated strftime
15 Feb 2024, 3:35 AM
#6
getaped avatar

getaped

New Zenner

Join Date:
Jul 2013
Posts:
9
Plugin Contributions:
0

Re: Shipstation Function strftime() is deprecated in 1.58

lat9:

FWIW, I replaced the return statement in the zen_datetime_short2 function with

return date('m/d/Y H:i:s', mktime($hour, $minute, $second, $month, $day, $year));  //- zc158 upgrade, replace deprecated strftime

thank you