• Resolved digitalblanket

    (@digitalblanket)


    Hi there

    First of all, thanks so much for this plugin – it’s been a lifesaver for this Events Manager Pro project I’m working on!

    I’m using the latest version and have found three problems. Not sure if either are because of my lack of expert knowledge, something wrong with the crappy client site I’ve taken over and am trying to fix, or a bug with the plugin.

    1. The plugin was throwing an error at (IIRC) line 84 of class.EwayPaymentsEventsManager.php, which converts country codes to country names. I am not using Beagle and so my understanding is that Country is not a required field in the registration form, is that not correct? I’ve gotten around the problem by hardcoding $countryCode in that same getCountryName function to AU, as I assume it was being passed in as blank. Should it even be calling this function if Beagle is not set-up in the admin?

    2. I am working in localhost, and when submitting the payment to eWay I was getting an error of “SSL certificate problem, verify that the CA cert is OK”. I hardcoded $this->sslVerifyPeer to FALSE on line 178 of class.EwayPaymentsPayment.php which fixes the problem. Keen not to compromise security when I go live though – is this likely to fail when live if I revert to TRUE?

    3. Trying to work out why the payment wasn’t going through because of the above two problems was tricky because the Events Manager Pro AJAX submit would just crash out with a 500 error. WP logs show “Call to undefined method EwayPaymentsEventsManager::set_error_message() in C:\xampp\htdocs\konnect-learning\wp-content\plugins\eway-payment-gateway\class.EwayPaymentsEventsManager.php on line 395” which was the function supposed to show me the eWay error of course. I can’t find the function set_error_message anywhere either – is this old error handling?

    Again thanks so much for this brilliant plugin! Glad I got it working, but I’d love to make it work in an upgrade safe manner with all security intact!

    Cheers
    Josh

    https://www.ads-software.com/plugins/eway-payment-gateway/

Viewing 6 replies - 1 through 6 (of 6 total)
  • Plugin Author webaware

    (@webaware)

    G’day Josh,

    1. thanks for the bug report! I’ll fix it for the next release, not this week but sometime this month. Yes, still needs to convert the country code if there is a country field even when not using Beagle, because the country name is used in the address which is passed to eWAY for your reference. OK, maybe not your reference, but other people’s reference ??

    2. Stop turning off CURLOPT_SSL_VERIFYPEER and fix your PHP config

    3. thanks for the bug report! That’s copypasta from the WooCommerce integration, will clean that up when I fix #1

    cheers,
    Ross

    Thread Starter digitalblanket

    (@digitalblanket)

    Awesome thanks Ross!

    1. No probs, I’ll add Country to the fields then, thanks for explaining!

    2. Oh excellent thanks, I’ll get that fixed!

    3. Thanks heaps!

    Also a question – I need to add a 0.5% surcharge to Amex and Diners transactions. Any suggestions on the best way? Thinking I need to hack your code to pass the first digit of the card number through to the em_eway_amount filter, but I may as well just add the surcharge directly to your code if that’s the case. Know of a better way than hacking your plugin?

    Thanks again!
    Josh

    Plugin Author webaware

    (@webaware)

    G’day Josh,

    No need to hack the code, just grab the credit card number from $_POST['x_card_num'] when you filter the amount with em_eway_amount.

    cheers,
    Ross

    Thread Starter digitalblanket

    (@digitalblanket)

    Brilliant, thanks Ross! I never realised you could access POST from a filter!

    Cheers
    Josh

    Plugin Author webaware

    (@webaware)

    G’day Josh,

    Just released v3.1.3 with fixes, please update.

    cheers,
    Ross

    Thread Starter digitalblanket

    (@digitalblanket)

    Hi Ross

    Sorry for the long delayed reply, but just wanted to let you know that the website has finally gone live this week. All worked perfectly in the plugin, thanks again for creating it.

    Cheers
    Josh

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘Two issues’ is closed to new replies.