• Hi,

    We have a contact form on a goDaddy hosting that sometimes cannot be submitted, and the loading spinner keeps spinning indefinitely.

    I have realized that, at least the following situation occurs:

    • Users click on the submit button (not sure how many times, reproduced with 2 or 3)
    • The spinner keeps rotating indefinitely

    Upon investigation, I noticed the /feedback ‘s api call response is an HTTP 429 Too many redirects, probably because of an anti brute force attack mechanism.

    The thing is, the error callback (catch) doesn’t handle network errors and only outputs the error to the console. The spinner doesn’t reflect the current state and users keep waiting when the request has been already fullfilled (unsuccessfully).

    How can we provide an error message when a network error occurs?
    Also, in order to prevent the user clicking more than once, how can I disable the submit button while the request is being processed? I tried myself by listening to the DOM events on the plugin documentation, but they always come in inverse order so the button ends up being disabled when it shouldn’t.

    Thanks for your time

Viewing 9 replies - 1 through 9 (of 9 total)
  • Plugin Author Takayuki Miyoshi

    (@takayukister)

    Where can we see the website in question?

    Thread Starter abages

    (@abages)

    Hi, thanks for your prompt reply

    The site is https://v9q.928.myftpupload.com/contact/. The same happens with our production site

    You can reproduce the problem by clicking 3 times to the send button. You’ll see the spinner keeps rotating even though the request failed (see network requests)

    Many thanks,

    Plugin Author Takayuki Miyoshi

    (@takayukister)

    What other plugins and theme do you use on the site?

    Thread Starter abages

    (@abages)

    Hi, we use:

    ACF Content Analysis for Yoast SEO
    Advanced Custom Fields PRO
    CF7 Smart Grid Design Extension
    Contact Form 7
    Contact Form 7 Apps
    Contact Form Entries
    Listo
    Polylang
    Popup Maker
    Post Types Order
    Simple Custom Post Order
    SVG Support
    Yoast Duplicate Post
    Yoast SEO
    Zero Spam for WordPress (disabled contact form 7 protection)

    Thanks

    Thread Starter abages

    (@abages)

    Sorry, I forgot to add the theme details.

    Theme is a custom one in-house that relies on Advanced Custom Fields

    Thanks

    Plugin Author Takayuki Miyoshi

    (@takayukister)

    Try switching to the default theme, deactivating all plugins excluding Contact Form 7, Listo and Yoast SEO, and clearing all cache data.

    Why you are advised to deactivate plugins and switch to the default theme.

    Thread Starter abages

    (@abages)

    Hi, thanks for your help

    Just by switching to the default 2025 wordpress theme I can see a difference: the form is not submitted via AJAX, and I can submit it several times with no errors

    How does the plugin know which technique (AJAX vs refreshing) needs to use?

    May the problem be caused by an interference caused by other plugins/theme code?

    Thanks in advance,

    Thread Starter abages

    (@abages)

    Hi, I disabled all the unnecessary plugins and flushed the cache but it doesn’t work.

    I also tried to listen to the DOM events (with and without wp_enqueue_scripts) and events are triggered in inverse order, so I cannot manually disable the button when nededed

    How can I disable the button when processing the submit request and enable it back when request has finished?

    Thanks,

    Thread Starter abages

    (@abages)

    Hi @takayukister, hope you are having a great day.

    Can you please help me with the spinner problem? How can I send the form data via AJAX and make the spinner react to network errors?

    Thanks in advance

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

The topic ‘Cannot submit form – loading spinner’ is closed to new replies.