WordPress.org

Ready to get started?Download WordPress

Forums

WooCommerce PayJunction Gateway
[resolved] Issue With WordPress 2.1 and Up? (21 posts)

  1. atrixdave
    Member
    Posted 6 months ago #

    Hello,

    After upgrading from WooCommerce 2.0.20 to 2.1, I started getting this error on the Order Confirmation page:

    {"result":"failure","messages":"
    \n\t\t\t
    Sorry, your session has expired. Return to homepage<\/a><\/li>\n\t\t\t
    Country<\/strong> is a required field.<\/li>\n\t\t\t
    First Name<\/strong> is a required field.<\/li>\n\t\t\t
    Last Name<\/strong> is a required field.<\/li>\n\t\t\t
    Address<\/strong> is a required field.<\/li>\n\t\t\t
    Town \/ City<\/strong> is a required field.<\/li>\n\t\t\t
    State<\/strong> is a required field.<\/li>\n\t\t\t
    Zip<\/strong> is a required field.<\/li>\n\t\t\t
    Email Address<\/strong> is a required field.<\/li>\n\t<\/ul>","refresh":"false","reload":"false"}

    Are you working on making this plugin compatible with WooCommerce 2.1 and above?

    On a side note, the PayJunction Woocommerce plugin shows up twice on my plugins list, and if I try to delete one of the listings, the entire plugin is deleted. Are you aware of this? Please fix.

    Thanks!

    https://wordpress.org/plugins/woocommerce-payjunction-gateway/

  2. dennis93q
    Member
    Posted 6 months ago #

    This is EXACTLY the same error we are as well... except it's not the paymentjunction plugin, but rather an authorize.net gateway plugin. The orders go through but throw that ugly error message!

  3. sbsake
    Member
    Plugin Author

    Posted 6 months ago #

    Is there a woocommerce bug in the update ?

    You make get a fresh copy of the plugin here

    https://company.payjunction.com/support/WooCommerce

  4. chuckers82
    Member
    Posted 6 months ago #

    There was some code change in woocommerce that affects the "thank you" page after you place an order. when can you review and make necessary changes this is affecting a lot of users.

    thanks

  5. dennis93q
    Member
    Posted 6 months ago #

    Yes, exactly. Is there any way to figure out what to change or any type of "regression/compatibility" setting or whatever that you can enable to have it continue to use the "thank you" slug or something we can hardcode somewhere?!? The orders do process... it DOES work..... the only thing that doesn't is this crazy error once the order is placed......

  6. chuckers82
    Member
    Posted 6 months ago #

    I believe it comes down to this set of code in the gateway-payjunction.php file

    -------------------

    // Return thank you page redirect
    return array(
    'result' => 'success',
    'redirect' => add_query_arg('key', $order->order_key, add_query_arg('order', $order_id, get_permalink(get_option('woocommerce_thanks_page_id'))))
    );
    else :
    $cancelNote = __('PayJunction payment failed', 'woothemes') . ' (Transaction ID: ' . $response->get_transaction_id() . '). ' . __('Payment was rejected due to an error', 'woothemes') . ': "' . $response->get_error() . '". ';

    $order->add_order_note( $cancelNote );

    $woocommerce->add_error(__('Payment error', 'woothemes') . ': ' . $response->get_error() . '');
    endif;
    }

    /**
    -------------------

    But i am unsure of how to fix to fit with the new woocommerce.

  7. chuckers82
    Member
    Posted 6 months ago #

    The developers need to chime in on this one and get us an update. it is causing a riff in sales on my site.

  8. atrixdave
    Member
    Posted 6 months ago #

    sbsake,

    As others mentioned previously, I believe you will need to modify the PayJunction plugin to account for a couple "Refactor" changes in version 2.1 and above of Woocommerce:

    Refactor - Removed pay and thanks pages. Endpoints are used instead.
    Refactor - Removed certain my-account pages. Endpoints are used instead.

    See the Woocommerce Changelog here for more info:

    http://wordpress.org/plugins/woocommerce/changelog/

    Please reply here when you have updated the plugin to account for this.

    Thank you!

  9. dennis93q
    Member
    Posted 6 months ago #

    The issue is that not every payment gateway plugin is currently supported. The plugin that we use has been working flawlessly for over 2 years now. All of a sudden, BAM. Not working properly. And by not working properly, i mean that end checkout complete screen.

    There HAS to be a way that WooCommerce can be modified to not throw this ugly error..... Like I said, even if it's a manual edit - it's better than nothing. Would allow us time to find another plugin if necessary, test it and implement.... or simply continue to use the payment plugins without issue.

  10. cfunkyk
    Member
    Posted 6 months ago #

    Check my post below on how to fix the PayJunction Payment Gateway so that it uses the new WooCommerce 2.1 endpoints.

  11. cfunkyk
    Member
    Posted 6 months ago #

    I fixed it:

    Change this:

    // Return thank you page redirect
    				return array(
    					'result' 	=> 'success',
    					'redirect'	=> add_query_arg('key', $order->order_key, add_query_arg('order', $order_id, get_permalink(get_option('woocommerce_thanks_page_id'))))
    				);
    			else :

    To this:

    // Return thank you page redirect
    				return array(
    					'result' 	=> 'success',
    					'redirect'	=> add_query_arg('key', $order->order_key, add_query_arg('order', $order_id, $this->get_return_url($this->order)))
    				);
    			else :

    The payjunction team should have had this fixed a long time ago...

  12. chuckers82
    Member
    Posted 6 months ago #

    It works! I knew it was that snippet but had no idea what needed to change. I blame both woocommerce and payjunction for the mess. I believe woocommerce should have warned users that this was a major upgrade and payjunction for not staying on top of what was going on with their plugin.

    Thanks again.

  13. atrixdave
    Member
    Posted 5 months ago #

    sbsake,

    If you guys don't fix this on your end soon I'm going to have to give this plugin a poor review due to lack of support.

    Sorry but c'mon..

  14. sbsake
    Member
    Plugin Author

    Posted 5 months ago #

    Thanks for the response. This will be updated over the weekend due to more testing that is currently being done.

  15. atrixdave
    Member
    Posted 5 months ago #

    Thank you sbsake, please reply here when the new version of the plugin is available.

  16. sbsake
    Member
    Plugin Author

    Posted 5 months ago #

    I have pushed the update and should be available shortly. This should resolve the issue that was encountered with WooCommerce update.

    Thanks for bringing this to our attention

  17. atrixdave
    Member
    Posted 5 months ago #

    Has anyone tested this? I'm still getting the following error:

    {"result":"failure","messages":"
    \n\t\t\t
    Sorry, your session has expired. Return to homepage<\/a><\/li>\n\t\t\t
    Country<\/strong> is a required field.<\/li>\n\t\t\t
    First Name<\/strong> is a required field.<\/li>\n\t\t\t
    Last Name<\/strong> is a required field.<\/li>\n\t\t\t
    Address<\/strong> is a required field.<\/li>\n\t\t\t
    Town \/ City<\/strong> is a required field.<\/li>\n\t\t\t
    State<\/strong> is a required field.<\/li>\n\t\t\t
    Zip<\/strong> is a required field.<\/li>\n\t\t\t
    Email Address<\/strong> is a required field.<\/li>\n\t<\/ul>","refresh":"false","reload":"false"}

  18. atrixdave
    Member
    Posted 5 months ago #

    sbsake? Any idea why this error is still showing up?

  19. atrixdave
    Member
    Posted 5 months ago #

    chuckers82, cfunkyk and dennis93q,

    Have any of you tried the new PayJunction plugin update? I'm still getting the error...

    I also tried to use cfunkyk's code swap and I'm still getting this same error.

    Any ideas? Very frustrating...

    Thanks,

    Dave

  20. sbsake
    Member
    Plugin Author

    Posted 5 months ago #

    Hi atrixdave

    The last update should have resolved this error. I tested this on a fresh wordpress site and have not found any issues. If you continue to have this issue i would

    - deactivate and delete the plugin
    - if you are using cache service make sure it is purged
    - add the payjunction plugin back within wordpress panel
    - activate plugin and update your api settings in woocommerce

    I hope this helps to resolve the issue

  21. atrixdave
    Member
    Posted 5 months ago #

    sbsake,

    I followed your instructions and it worked! Thank you for your support!

Reply

You must log in to post.

About this Plugin

About this Topic

Tags

No tags yet.