• Resolved danescobar

    (@danescobar)


    Hi,

    My checkout page throws this error anytime I want to proceed to Sandbox Paypal, making a purchase. As it involves fbevents.js and checkout.min.js it could be a bug caused by your plugin or Woocommerce’s. Also I’m using your other plugin for creating FB product feeds.

    The error the checkout returns after clicking on Proceed to Paypal is:

    SyntaxError: Unexpected token D in JSON at position 2

    When checking the tool XHR and Fetch the console throws these js errors:

    [DOM] Found 2 elements with non-unique id #_wpnonce
    <input type="hidden" id="_wpnonce" name="_wpnonce" value="b54635f4c7"> and eb9f44e055
    Unable to fix malformed JSON | checkout.min.js
    Resource interpreted as Document but transferred with MIME type image/gif facebook.com/tr | fbevents.js

    Also when I check mywebsite.org/checkout/?wc-ajax=checkout the page throws this text:

    {"result":"failure","messages":"<ul class=\"woocommerce-error\">\n\t\t\t<li>We were unable to process your order, please try again.<\/li>\n\t<\/ul>\n","refresh":true,"reload":false}

    Thanks for the attention and I hope we can fix this.

    The page I need help with: [log in to see the link]

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author PixelYourSite

    (@pixelyoursite)

    I tried to replicate this error on your website, but everything worked fine.

    If you still have it, disable PixelYourSite and try again. If the error persists, send me a message on our support page: https://www.pixelyoursite.com/contact

    Thread Starter danescobar

    (@danescobar)

    Yes, it occurs randomly.

    A couple of hours after I posted this message I managed to fix the Paypal redirection but I don’t know what fixed it. I tried several times deactivating WP Supercache and Autoptimize and deactivating/reactivating Paypal Sandbox in Woocommerce.

    Despite this, the XHR console errors persist and are reproducible despite the correct redirection.

    Do they give some insight on what may be duplicating _wpnonce or why the resource is tranferring as a gif MIME type by fbevents.js? I don’t want this error to appear again at random.

    Plugin Author PixelYourSite

    (@pixelyoursite)

    I’m glad that you fix it. I suspect one of your optimisation/cache plugin was creating this problem.

    It doesn’t look like something related to our plugin, so I’ll mark this topic as fixed.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Unable to redirect to Paypal at checkout because of duplicate id _wpnonce’ is closed to new replies.