Forums

This topic is locked

Creating recordset from Session variables

Posted 06 Oct 2003 16:46:11
1
has voted
06 Oct 2003 16:46:11 tom dood posted:
Two questions really:

1. Is there a way to set a session variable from a select list without using a submit button? Is it possible to adapt a jump-menu, for example, so that the user selects their preference and it immediately creates the relevant session variable?

2. I am setting up a dynamically based site to link with a paypal shopping cart. I am trying to allow users to select a shipping rate and for that rate to be stored as a session variable - but it seems the button to submit to paypal won't also function as a submit button for the session variable. Any ideas on why & a workaround ?

3. Once I have a session variable stored, I would like to be able to link the value of the variable to a mysql table in a recordset. I assumed I could do this simply by making the value of the session variable = the relevant column in the table, but I'm not getting any results. Wondering why.

Many thanks for any bright ideas.

cheers

Replies

Replied 26 Oct 2003 15:29:43
26 Oct 2003 15:29:43 Carl Grint replied:
This may work if you add some hand coding to the jump menu to point at a page which would generate the Session from the list value and then move to the distination page.

Make this page with no body content, just ASP content.

The Session would be simple in this page:

Session("Shippingrate"=Request.Querystring("Shippingrate"

use a Response.Redirect to specify to the page to move to once the Session is completed.


Back in your page with the Jump menu, use something similar to the follow code in your jump menu:

option value="page.asp?Shippingrate=rsrecordset("column""Rate

Reply to this topic