Support

Home Forums Event Espresso Premium Authorize.net Test Mode Bug

Authorize.net Test Mode Bug

Posted: November 29, 2018 at 11:03 am

Viewing 1 reply thread


Masen

November 29, 2018 at 11:03 am

We set up Authorize.net, but we were unable to get a test transaction to go through successfully.

We found there’s a quirk when saving changes to the auth.net settings. It tries to verify that the image defined in the “Button URL” field actually exists. It can’t do that because the site has an http basic auth setup, so we can’t save any of the changes when that value is set. Instead we need to remove the image file definition and then manually add it to the database afterward. The SQL to do this is:
UPDATE wp_esp_payment_method SET PMD_button_url = ‘https://<domainname.<extension>/wp-content/plugins/event-espresso-core-reg/payment_methods/pay-by-credit-card.png&#8217; WHERE wp_esp_payment_method.PMD_ID = 10;

We thought the keys might be incorrect, but found that was not the case.

The code in the Event Espresso plugin doesn’t properly support test mode. We debugged the plugin and found that it doesn’t actually set the “x_test_request” flag even though test mode is enabled. We added the following to the 3rd line of the _sendRequest function in plugins/event-espresso-core-reg/caffeinated/payment_methods/Aim/EEG_Aim_gatewya.php:
if ($this->_test_transactions) {
$this->_x_post_fields[‘test_request’] = ‘Y’;
}

After adding that line the test transaction went through.

The downside is that this will be overwritten if/when the plugin is upgraded.

However, when we are in live mode it shouldn’t have any problem since it works properly with the live mode. It will only be a problem when testing.

FYI, the table “wp_esp_log” contains a log of every request to and response from the Auth.net API. That’s a good place to look to see what is actually being sent to the server.

With that said, the question is: Will Event espresso fix this in a future version of the plugin?

Thanks for your assistance.


Josh

  • Support Staff

November 29, 2018 at 11:30 am

Hi,

Thanks for sharing this detailed report. Two things:

1) If the image can’t be loaded to verify the correct URL on the settings page, another workaround that doesn’t involve database manipulation is just use an image that can be loaded, like this one:

https://ee-screenshots.s3.amazonaws.com/2015/07/pay-by-credit-card.png

2) The test mode issue can be fixed in a future version, pending triage and prioritization. If you’d like to help make that happen sooner than later, the development team welcomes pull requests on the hosted code repository for Event Espresso 4 core:

https://github.com/eventespresso/event-espresso-core/

Viewing 1 reply thread

The support post ‘Authorize.net Test Mode Bug’ is closed to new replies.

Have a question about this support post? Create a new support post in our support forums and include a link to this existing support post so we can help you.

Event Espresso