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

Pass variable through Frames to new Page in HREF

Status
Not open for further replies.

Bastien

Programmer
May 29, 2000
1,683
CA
What I have is a dynamic index being generated by a SQL query. I base the query on a user input of a clisnt id in frame 1 text box with the client id being passed through a submit button.

The index is built in frame two. Up to here it works fine. The index is a series of <A HREF = &quot;some_page.asp&quot;> tags that allow th user to choose what page to see next in the main_frame (#3). I can't find a way to pass the client id and retrieved client name through to the 3rd frame. I have tried querystring and Javascript's form.submit. Nothing seems to work and I need the client ID to run the query on the main_frame to fill in the fields.

Any help will be appreciated?
Bastien
 
Hello

You can do two things, if it's a submit form, you should always pass the information from the form to the next ie...using submit and using ASP's Request.Form to retrieve the information. That way you have to keep passing the information to all the pages..

if you don't have a submit form, and using query string, then you should always pass the information by query string. That means all redirects and links you should always put a ?id=(whatever) and keep passing it to each of the pages.

The third solutions is to store the id into a Session variable, that way the information is stored until the Session has expired.

to store
Session(&quot;ClientID&quot;) = 1

to retreieve
clientid = Session(&quot;ClientID&quot;)

And also remember this is ASP u have to use <% and %> for asp code.

Hope that helps..

Hui
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top