Need to get a form to submit multiple outputs for each input under a heading.

Highlighted
New Member
1 0 0

Hello,

 

I am running into a problem with a form I am coding up for our site. I have it coded so that there are multiple inputs under the same heading, but when the form is submitted only one output is sent to our email. Was wondering if there is a fix for this. I've attached some screenshots below of the code and form section that I need assistance with. Let me know if there is anything else I need to provide.

 

Thanks so much,

 

Tucker

 

Screenshot 2019-11-11 15.13.41.pngScreenshot 2019-11-11 15.13.22.png

0 Likes
Shopify Expert
51 12 7

Hey Tucker,

 

For the text input fields, you'll need to modify the name attributes to be unique. You could simply add numbers to the end of each current text input like this example:

 

<input type="text" name="contact[Item #/Name 1]">
// Next Row
<input type="text" name="contact[Item #/Name 2]">
// Next Row
<input type="text" name="contact[Item #/Name 3]">
Etc...

 

I also suggest you make the "id" and "for" attributes unique for all inputs.

 

Let me know if you need any more help.

0 Likes