Passing form variables 2 or 3 pages forward
You then go to checkout to put your name and address in and pick PAY, your get directed to a secure page to put cc details in. Once you have your order is added to a MySQL database. I need the discount word to appear in the MySQL database as well but this is inserted 2 or 3 pages after the discount word.
If Request.Form("searchstring1") <> "" Then
**Database connection stuff here**
set rs=conn.execute("SELECT * FROM discount where discountword = '" & search1 & "'")
If Not rs.EOF Then
Session("DiscountAmount") = rs("discountamount")
Session("DiscountValue") = rs("discountvalue")
Session("Discountword") = rs("discountword")
If Session("DiscountValue") = "" Then Session("DiscountValue") = "1"
If Session("DiscountAmount") = "" Then Session("DiscountAmount") = "0"
In the example about I have (wrongly or rightly) set it is a session variable. How do I use this on the page that is submitting to the MySQL db? As it's a session can I just use a <INPUT TYPE="hidden" NAME=" etc as normal or do I have to do something to jump the variable on across the page?