View Full Version : moving value to other page via link

05-10-2008, 09:42 PM
suppose that i have like folllowing link in y.php

<a href='x.php?t=".$row["z"]."'>zodehala</a>

when i clicked this link how can i move value of $row["threadid"] variable to x.php

05-11-2008, 12:28 AM
<a href='x.php?t=<?php echo $row['z']; ?>&id=<?php echo $row['threadid']; ?>'>zodehala</a>

Where id is the name of the GET variable that you want for $row['threadid']

05-11-2008, 02:39 AM
Not sure if this is what you're asking, but in x.php, you'll need a line like:

$variable = $_GET['t']; // $variable becomes the value of t= in the URL's query string

If you're going to do anything with that variable BE CAREFUL! People can easily inject script or SQL commands into GET variables causing very dangerous results.


EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum