NetSmith
asked on
Dynamic Form to Mail
I'm trying to build a dynamic form that allows users to choose spare parts (and quantities of) for a variety of products.
Depending on the product chosen, the form displays the name and a quantity box for each spare part that's available. The quantity box is dynamically named, so that I can pass the data using the #FORM.fieldnames# method.
Unfortunately, the actual spare part numbers & names all contain hyphens or spaces so I'm running into problems with passing the data.
I'm now working on an approach to assign a temporary identifier to pass the data and then convert it back to show the real values to the supplier when they receive their email. Needless to say I'm having difficulty with this.
This is not for a shopping cart. It's function is simply to send an email requesting a quote from the supplier.
Hope you can help. Thanks in advance.
Depending on the product chosen, the form displays the name and a quantity box for each spare part that's available. The quantity box is dynamically named, so that I can pass the data using the #FORM.fieldnames# method.
Unfortunately, the actual spare part numbers & names all contain hyphens or spaces so I'm running into problems with passing the data.
I'm now working on an approach to assign a temporary identifier to pass the data and then convert it back to show the real values to the supplier when they receive their email. Needless to say I'm having difficulty with this.
This is not for a shopping cart. It's function is simply to send an email requesting a quote from the supplier.
Hope you can help. Thanks in advance.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Thanks for the help. I went down a different road in the end, using Structures, but the advice was good - thanks again.
yeah structures is also a neat way to go ...
but ive always prefered using list & love playing with them ... so ... :)
thanx for the points thou
Cheers,
Anand
but ive always prefered using list & love playing with them ... so ... :)
thanx for the points thou
Cheers,
Anand
You shoudn't try to use regular names as ColdFusion variables.
<input type=text name=part#part_id#_quantit
<input type=hidden name=part#part_id#_name value="#part_name#">