I've tracked down the reason that the cron job triggers the error reported in my last post.
It appears that with the latest host changes that $PHP_SELF and (most?) $_SERVER variables are empty when the script is run from cron. The code in includes/classes/payment.php failed to find the square payment module because it extracts the script type (.php) from the $PHP_SELF variable.
My patch to get around this problem was to set $PHP_SELF to __FILE__ if $PHP_SELF was empty in square_handler.php near line 13:
All seems well now.Code:require 'includes/application_top.php'; if (empty($PHP_SELF)) $PHP_SELF = __FILE__; // ensure that $PHP_SELF is not empty require DIR_WS_CLASSES . 'payment.php';


Reply With Quote
