Jump to content

[SOLVED] Give Value to a Variable via Mouse Click


xProteuSx

Recommended Posts

I am trying to assign a value to a session variable by having the user click on a link.  Here's the idea:

 

I am building a glossary.  On page1 the user clicks on a letter, A-Z, and this takes them to a page where all terms for the letter they select are displayed.  So if they click on the letter 'C" it will take them to the 'C' page, where all terms for the letter C are.  The definitions are stored in a DB, and I do not have any problems querying the DB.  However, I do not know how to go about setting a session variable when they click on a letter.

 

I want this:

 

1.  User clicks on 'C' on page1, setting session variable to 'c'

2.  Click takes them to page2 which queries the db for all terms starting with 'c' or 'C' and displays them in alphabetical order.

 

Who do I set the variable with a mouse click on a link, then have it passed to page2?

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.