Ask a Question related to Coldfusion - Getting Started, Design and Development.
-
kelryu #1
Dynamic form problem
I have a form that generates dynamic fields that the user can fill. The problem
I'm having is with the form processing. So for example if a user created three
new lines each containing 4 fields of input (eg. name, addr, zip) i need to
check that each line has every single line filled before i process it.
As for now I name every field the same thing but add a number to it, so for
instance if the user creates a new line then the name field is "name1" because
it is in line 1 line 2 would contain "name2".
The problem is in the processing, i have an idea of what i want to do but cant
do it. I create an index loop and loops through but when i try to create
form.name#i# i get an error. The error says form.name does is undefined, so it
does not add the #i# variable to form.name before evaluating. I also tried
form.name&#i# and i still get the same error.
So right now I'm stuck. I dont know how to evaluate the dynamic fields. Any
ideas?
Thanks.
kelryu Guest
-
Ins. Record from dynamic form problem
XP Pro, CF 6.1(built in webserver), MySQL 4.1.13, DW MX04, I am trying to insert a records from a dynamic form. I created it all in Dreamweaver MX... -
Insert record from dynamic form problem
XP Pro, CF 6.1(built in webserver), MySQL 4.1.13, DW MX04, I am trying to insert a records from a dynamic form. I created it all in Dreamweaver MX... -
Dynamic form to create pie chart - problem reprentingthe data not selected by user
I have created a pie chart based on what a user select on a form. For example, a user can select from a list of species they want to view a pie... -
Creating a Dynamic form
I want to create a form where the user enters their family members' names and ages. An input on the form will ask the user to enter the number of... -
Dynamic form population
The addition of flash & XMl forms in CFMX7 is great. Just wondering if there is a way to dynamically populate a field based on another (i.e. from... -
mxstu #2
Re: Dynamic form problem
FORM is like a structure. You can access form field values using array
syntax, like:
<cfloop .... index="i">
<cfset localName = FORM["name"& i]>
<cfoutput>#localName#</cfoutput>
</cfloop>
Btw, you may also want to search the forums. Handling dynamic form fields is
a popular question :-)
mxstu Guest
-
kelryu #3
Re: Dynamic form problem
Thanks. Problem solved and next time i'll be sure to use the search button first.
kelryu Guest



Reply With Quote

