Product collection name in form submission

Good evening all,

I have an enquiry form on a collection template product page which should allow the user to request more info about said product, along with their own personal data like name, phone and email etc for the clients team to contact them. The form submission therefore must show the product name so the client knows what product the user is referring to with their enquiry.

Does anyone know how I can have that collection product name feature in the email submission please?

Thanks for your help.

Benji

Read-only link: Webflow - Ritmo Office (the form is at the bottom of the page)

This is one of those questions that gets asked often. As such, there are many posts that show how to solve it.

Here is one

Thanks @webdev, but I have done everything highlighted in the post and video but it’s not working when published.

Please can you check what I have done is correct (via my share link)? Would really appreciate it.

Thanks for your help.

Benji

Where is the embed with the hidden field via HTML inside the form with the matching ID referenced in your code block? Also when you want to debug code you need to visit the page on the front end since code does not run in the back end. So a link to a collection item in that collection should be provided.

@webdev In the post he recommends to add the code in the /body custom code area and not the page itself and referencing the hidden input field ID, in this case ‘prod-name’.

Screenshot 2023-01-07 at 10.50.05 AM

What is it that’s not working?

https://ritmouae.webflow.io/products/gito

image

Hi @memetican, in the email correspondence we need to highlight the product name the user is enquiring about. What you have pointed out is the front end indicator for the user to know what product they are enquiring about.

I am referring to the product name in the email the client receives so they know what product the user enquiring about (context).

Hope that’s clear.

Thanks for your help.

Ah, I thought at first that was being set by your script as well as a test.
Got it.

The problem seems to be that you’re missing <script> </script> tags.

image

Lol, thanks @memetican! Schoolboy error! Working now.

Thanks for your help.

1 Like