• Resolved Ivan Nugraha

    (@mangwp)


    The issue shown up on single product page paypal button. I suspected there is some issue with WP-Rocket caching even though all js in plugins folder is being excluded from optimization

    /wp-content/plugins/woocommerce-paypal-payments/(.*).js

    Woo Log says:
    2023-08-24T07:21:21+00:00 ERROR Cart updating failed: Could not validate nonce.
    DEBUG POST https://api.paypal.com/v1/oauth2/token?grant_type=client_credentials Response Debug ID: xxxxxx
    Response: Array ( [code] => 200 [message] => OK )

    On Browser console:
    create_order_error
    click_initiate_payment_reject

    The strangest part is, the issues is solved when wp-rocket cache is cleared, but on next day its always showing up again.

Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Support Syde Joost

    (@joostvandevijver)

    Hello @mangwp

    Thank you for reaching out to us, we are here to help.

    We have encountered a similar issue before with WP-Rocket, in that case it was causing the JavaScript that our plugin uses to not be allowed to run. It seems you are encountering a similar situation, so I do think the same should work for you. The merchant that encountered this before, told us that he “put the JavaScript out of WP-Rocket minification, and it solved the problem”.

    Other than that, we did not get many more details, but I do believe the solution for this issue should be found via the settings of WP-Rocket.

    Please give this another try and let us know if you believe we should take a look from our side and how you think our plugin can avoid this situation.

    Kind regards,
    Joost

    Thread Starter Ivan Nugraha

    (@mangwp)

    Hi, thanks for replying. I did excluding js script which come from paypal plugin, but so far no luck.

    Here is list of file being excluded:

    /wp-content/plugins/elementor-pro/assets/js/frontend.min.js
    /wp-content/plugins/woocommerce-paypal-payments/(.*).js
    /wp-content/plugins/woocommerce-paypal-payments/modules/ppcp-button/assets/js/button.js
    /wp-content/plugins/woocommerce-paypal-payments/modules/ppcp-vaulting/assets/js/myaccount-payments.js
    /wp-content/plugins/woocommerce-paypal-payments/modules/ppcp-wc-gateway/assets/js/oxxo.js
    /wp-content/plugins/woocommerce-paypal-payments/modules/ppcp-wc-gateway/assets/js/pay-upon-invoice.js
    /woocommerce-paypal-payments/modules/ppcp-wc-gateway/assets/js/gateway-settings.js
    paypal.com

    I was get in touch with WP-Rocket support, lets see if they have answer for the problem.

    Plugin Support Syde Joost

    (@joostvandevijver)

    Hello @mangwp

    Thank you for updating us. You might also want to perform a standard conflict test and see if possibly other plugins could also add to this problem?

    I’ll leave this thread open and wait for your response on this.

    Kind regards,
    Joost

    Plugin Support Syde Joost

    (@joostvandevijver)

    Hello,

    Since we did not receive any response or follow-up questions from you, we will assume you got this working to your requirements. If you still have any more questions for us, please open a new thread, because we will mark this one as resolved.

    Kind regards,
    Joost

Viewing 4 replies - 1 through 4 (of 4 total)

The topic ‘“Something went wrong. Please try again or choose another payment source.”’ is closed to new replies.