• Resolved teran123

    (@teran123)


    Hello. I’m trying to connect Square for payment on a custom order form, but I always get the error “Payment nonce is not specified” in response. Also in the console I see the error “Uncaught FormNotReadyError: Cannot call SqPaymentForm # requestCardNonce before the paymentFormLoaded () callback.”

    Can you please tell me what could be the problem?

    Order Form: https://happiestours.devteam.host/order-form/ (valid zipcode 92331)
    Default checkout page has the same error. (https://happiestours.devteam.host/checkout/)

    • This topic was modified 3 years, 5 months ago by teran123.

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

Viewing 6 replies - 1 through 6 (of 6 total)
  • Hi @teran123,

    Thank you for reaching out to us! This particular error is almost always caused by a conflict of either the theme or a plugin on the site. Please follow this thread for steps on how to resolve this.

    If it does not resolve this, please reply with the Status Report of the site, found in WooCommerce > Status.

    Thread Starter teran123

    (@teran123)

    https://pastebin.com/hPfX0kRW

    • This reply was modified 3 years, 5 months ago by teran123.
    Plugin Support Sol J. a11n

    (@solstudioim)

    Hi there @teran123

    I hope you’re well.

    Thanks for sharing the status report of your site.

    As we mentioned before this kind of issue is usually caused by a theme/plugin conflict.

    Please complete the steps below to determine if there is a conflict with your theme/ plugins:

    • Temporarily switch your theme to Storefront
    • Disable all plugins except for WooCommerce and Square
    • Repeat the action that is causing the problem.

    If you’re not seeing the same problem after completing the conflict test, then you know the problem was with the plugins and/or theme you deactivated.

    To figure out which plugin is causing the problem, reactivate your other plugins one by one, testing after each, until you find the one causing conflict.

    You can find a more detailed explanation on how to do a conflict test here.

    Let me know how it goes!

    Thread Starter teran123

    (@teran123)

    I understand that the problem is with the theme, but I am a theme developer and cannot trace the cause deeper.

    Plugin Support nicw.a11n

    (@nicw)

    Hi there

    Tracking the error you mention would be your best best:

    Uncaught FormNotReadyError: Cannot call SqPaymentForm#requestCardNonce before the paymentFormLoaded() callback.

    It seems the card nonce is being requested before the entire payment form is loaded/initialized. This may have something to do with the way the form is being called but hidden.

    This means the payment form is missing the required nonce.

    The error does mention further documentation: See Step 4: https://developer.squareup.com/docs/payment-form/how-it-works#the-sqpaymentform-process-flow

    Nico

    (@nicolamustone)

    Automattic Happiness Engineer

    We haven’t heard back from you in a while, so I’m going to mark this as resolved – we’ll be here if and/or when you are ready to continue.

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