
November 5th, 2002, 07:38 PM
|
|
Registered User
|
|
Join Date: Apr 2007
Posts: 22,309
Time spent in forums: < 1 sec
Reputation Power: 24
|
|
|
passing a variable through if statement
i need help passing a variable through an if statement...
the link im using is:
echo "<a href="$PHP_SELF?cat">$name</a> ($numrows)<BR>";
elseif($_SERVER['QUERY_STRING'] == "cat") {
include('cat.php');
}
how can i pass a variable like $cat_id through this if statement and show up for cat.php?
it works fine if i use a link straight to cat.php like:
echo "<a href="$PHP_SELF?cat_id=$cat_id">$name</a> ($numrows)<BR>";
|