HOW TO: Integrate Hosted Checkout with the Wordpress eShop Plugin

This tutorial was conducted with Wordpress 3.0.1 and eShop 5.7.7
STEP 1: Install and activate the eShop plugin in your Wordpress installation.
STEP 2: Make a local copy of the “authorizenet.php” file in the “eshop” plugin directory and open it in your text editor.
STEP 3: In this file, look for any instances of the following URL:

and replace them with this one:

STEP 4: In the same file, look for instances of this URL:

and replace them with this one:

STEP 5: Save this file and upload it to your web server, replacing the existing “authorizenet.php” file. The plugin will now use E-xact as its payment gateway for the “” payment option in eShop.

STEP 6: Log in to your Wordpress installation and go to Settings -> eShop -> Merchant Gateways.

STEP 7: Enable the payment option, enter your Payment Page ID into the API login ID field, and input your Transaction Key. If you plan on using Relay Response, you'll also want to enter your Response Key into the "MD5-Hash Phrase(was Secret Answer)" field.


You’ll also want to change the Currency Code setting to its appropriate value under the “General Settings” section on this page.


STEP 8: The last step is to configure eShop to use the receipting method of your choice. Note that Silent POST is not supported by the eShop plugin.

Option 1 - Relay Response

eShop is set up to use the Relay Response method by default, and creates a page for use with this method automatically. You can find out the URL for this page by logging in to Wordpress, and clicking "Pages". Here, you should see a page called "- Thank you for your order". Click the "View" link for this entry and copy the URL for this page. Now you’ll want to add it to the “Relay Response URL” field under the “Receipt Page” tab in your Payment Pages administration area. Note that if you wish to use the “Validate Relay Response HTML” option, you’ll need to modify the eShop plugin to support this, as it does not support this type of validation by default.

Option 2 - Receipt Link

If you do not wish to use the Relay Response method and would prefer to use one of the Return Link methods, you can disable Relay Response by opening the “authorizenet.class.php” file in the eshop/authorizenet directory, and replacing these lines:

	<input type="hidden" name="x_relay_response" value="TRUE" />
<input type="hidden" name="x_relay_URL" value="'.$relayURL.'" />

with these:

	<input type="hidden" name="x_relay_response" value="" />
<input type="hidden" name="x_relay_URL" value="" />

After making this change you’ll need to replace this file on your server with the modified version. Note that if you choose this method, you cannot use the GET or AUTO-GET options as none of the values returned from these will be processed, though POST and AUTO-POST requests should still process normally.

Have more questions? Submit a request


Please sign in to leave a comment.
Powered by Zendesk