Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Multiple page data entry form

Status
Not open for further replies.

cctrinh

MIS
Feb 2, 2001
25
US
Hello,

I need to build a multiple page data entry screen for users to enter information into the DB table. There are many fields I need to capture and store in a table. Some of the fields are multi line text field for the users to enter a few lines of text in a textbox. But right now, I wasn’t sure which approach I should take.
1. Use session variables to capture the data as the users are completing the multiple page data entry then store all the values at the end when the user finish entering all the data.
2. Create a temporary table in a DB to capture the data until the user is finished then store the values in the temporary table back to the real table.

I hope someone can provide me with some suggestions on this. Thank you in advance for your help.
 
Stick this snip of code in all form pages after your first one. It takes all values from the previous form and puts them into hidden form fields in the current form. Then, when you get to the end you have all of the values in the form scope to enter into the database.
Code:
<cfoutput>
  <cfloop list="#form.fieldnames#" index="f">
    <input type="hidden" value="#FORM[f]#" name="#f#">
  </cfloop>
</cfoutput>
That way, all of your forms act naturally and you don't have to worry about fooling with sessions or temp tables.

Hope This Helps!

ECAR
ECAR Technologies

"My work is a game, a very serious game." - M.C. Escher
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top