No verified submissions or spam from form

I’ve followed the documentation and also the troubleshooting guides but cannot get the form to work. Here’s what I’m doing in gatsby:

<form 
   className="contact-form"
   name="Contact"
   name="contact"
   method="POST"
   action="https://getform.io/f/7f3a51aa-80b3-41f6-bea8-588b9d5f03da"
   data-netlify="true"
   netlify-honeypot="bot-field"
  >
                <input type="hidden" name="bot-field" />
                 <input type="hidden" name="contact" value="contact" />
                <label>
                  Name*
                  <input type="text" id="name" name="name" />
                </label>
                <label>
                  Email*
                <input type="email" id="email" name="email" />
                </label>
                <label>
                  Message*
                  <textarea id="message" name="message" />
                </label>
                <button type="submit" className="button button--primary">Submit</button>
              </form>

For some reason, you’ve added the name attribute twice.

Also, the action attribute is pointing somewhere else. Point it to # or something. That should work.

1 Like

Hi thanks for taking a look. I removed the extra name attribute and pointed action to # and there are still no submissions

I just tried using your form code in my Hugo website and noticed that, <textarea> when closed inline like <textarea/> doesn’t work. Can you try adding a separate closing tag like <textarea> </textarea>? The Netlify forms docs: Forms setup | Netlify Docs also close the <textarea> by using a separate closing tag. Because other than that, I don’t see a reason why it shouldn’t be working.

thanks again. I’ve done this but still no dice…

Assuming that this is the correct URL: https://stoic-jennings-d275f4.netlify.app/contact-us/, I don’t see any data-netlify = "true" attribute on the form.

If that’s not the correct page, can you share the URL to the test page or the source code of the contact form that’s updated.

This is the code I received from the link I mentioned:

<form class = "contact-form" name = "contact" method = "POST" action = "/success/">
  <input type = "hidden" name = 'form-name' value = "contact"/>
  <input type = "hidden" name = "bot-field"/>
  <input type = "hidden" name = "contact" value = "contact"/>
  <label>
    Name*
    <input type = "text" aria-required = "true" id = "name" name = "name"/>
  </label>
  <label>
    Email*
    <input type = "email" aria-required = "true" id = "email" name = "email"/>
  </label>
  <label>
    Message*
    <textarea aria-required = "true" id = "message" name = "message"></textarea>
  </label>
  <button type = "submit" class = "button button--primary">
    Submit
  </button>
</form>

As you can see, no Netlify attributes have been mentioned.

Also, <input type = "hidden" name = "contact" value = "contact"/> is mentioned twice.

That’s the correct URL. Here is what I have pre build:

<form
    className="contact-form"
    name="contact"
    method="POST"
    action="/success/"
    data-netlify="true"
    netlify-honeypot="bot-field"
>
    <input type="hidden" name="bot-field" />
    <input type="hidden" name="form-name" value="contact" />
    <label>
        Name*
        <input aria-required="true" type="text" id="name" name="name" />
    </label>
    <label>
        Email*
        <input aria-required="true" type="email" id="email" name="email" />
    </label>
    <label>
        Message*
        <textarea aria-required="true" id="message" name="message"></textarea>
    </label>
    <button type="submit" className="button button--primary">Submit</button>
</form>

It is showing as an active form in the dashboard. I am unsure why the attribute is missing post build

this is now working!

thanks for your time looking into it. I believe the problem was in duplicating this and putting the same name attribute in as the form element’s name attribute when it should have been "form-name"

<input type="hidden" name="form-name" value="contact" />
2 Likes