Page 1 of 1

Idea needed: How to pass a value to a page with a click?

Posted: Wed May 18, 2005 11:26 am
by Ir0nSpIkE
Hi

I'm a Newbie looking for ideas: I'm generating a list of clients in a loop and displaying them as a link. I want to open the new page and pass it a Client ID so I can run a new query to display more info. But How?

Posted: Wed May 18, 2005 11:34 am
by neophyte
It's called a Query String and you add it to your link in this fashion:

Code: Select all

<a href=&quote;somepage.php?someval=1234&quote;>link</a>
Then you get the value like this:

Code: Select all

echo $_GET['someval']; //outputs 1234

Posted: Wed May 18, 2005 11:54 am
by Ir0nSpIkE
THANKS! :D