Hello friends,
What is wrong with the following codes:
file1.php
<?
$Connection = mysql_connect ("localhost", "root", "Samira");
$database = mysql_select_db("customer");
$query = "select * from trainer order by TrainerName";
$result = mysql_query($query);
echo "<table align = center border =1 width = 100%>
<tr align = center><td><b>Number</td><td><b>Trainer Name</td><td><b>Category</td><td><b>Telephone</td><td><b>Email</td>
<td><b>Biodata</td></tr>";
while($rec = mysql_fetch_object($result))
{
echo"<tr bgcolor = '$c'><td>$count</td><td>$rec->TrainerName</td><td>$rec->Category</td><td>$rec->Telephone</td><td><a href = 'mailto:$rec->Email'>$rec->Email</a></td>
<td><a href = \"file2.php?test = ".$rec->ID."\">Click here to see Biodata</a></td></tr>";
$count++;
}
?>
The problem occured when I want to run file2.php. The value of variable test will not be transferred to file2.php. I have tried by using:
$test = $HTTP_VARS_POST['test']; at the beginning of file2.php. But $test holds nothing. The comiler is complaining about 'undefined index test....'
So, would you help me?
ThanX
Solomon