Michael,

Glad to hear you finally got to the bottom of your problem - and sorry that you had to do this largely by yourself.

Which version of PHP is installed on your server?

I've eventually got round to doing some research as to why you had to change the code in includes/templates/template_default/templates/tpl_wpcallback_default.php as you indicated eg:

Code:
if(isset($HTTP_POST_VARS['transId'])) {$transId = $HTTP_POST_VARS[transId];}
to

Code:
if(isset($_POST['transId'])) {$transId = $_POST[transId];}
etc.

It seems that $_POST was introduced in PHP v4.1 The data contained in this array is global.

$HTTP_POST_VARS contains the same data as $_POST but the data is NOT global.

For versions of PHP before v4.1 $HTTP_POST_VARS needs to be used or the code won't work. This is used in the WorldPay module since it should work for versions of PHP both before and after v4.1.

EXCEPT that $HTTP_POST_VARS is now deprecated and is now turned off by default in newer versions of PHP (v5.1 on).

So for all versions of PHP up to v 5.0 the current code will work. For servers with PHP v5.1 and above it won't work by default.

The solution is to either configure the server so that $HTTP_POST_VARS is turned on or replace the existing code with the new code as per your post.

Does anyone know of a more elegant solution, one which allows the code to work regardless of PHP version? Or should all code now use $_POST with the expectation that everyone should be using PHP 4.1 or greater?

I imagine this will effect other areas of ZenCart.

Regards,

Alan