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 IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Form validation

Status
Not open for further replies.

demchak

IS-IT--Management
Jun 29, 2001
36
US
Hopefully this isnt to bad....
I have a web that links into a SQL DB. It is used to update records. As of now when you input info and hit enter on the form it updates the DB with an insert query. In order to limit the number of errors they would like to send the info to a validation page that pulls some info from the DB and asks if this info is correct then gives a "continue" or "back" option.
ex.

I enter my employee# and a class# on formPage.

I get a validation page that says John Smith, where the name was pulled from the DB, attended Class1, where Class1 was pulled from the DB also.
I hit enter on valiPage to confirm which sends the origional info, employee# and class#, to submitPage where it is submitted.

My problem is that i can not figure out how to send the employee# and Class# info from valiPage to submitPage without having the user enter it again!

TIA for any help
 
Sounds like you need a variable
You can set a javascript var that is equal to the original form post, then do a document.write to view on the page as well as writing it to a hidden form field on the second page. I am not an expert but something to this affect:
1st page:
<script>
var name=document.myform.name
var class=document.myform.class
</script>

2nd page
<script>
document.myform.name=y
</script>
<form>
<input type=hidden name=name>
The Name Is: document.write=y
</form>
See the javascript guys or use FP's built in asp
DeZiner
gear.gif width=45 align=left
When the gears stop turning,
we all stop learning.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top