Hello.
I have a script that is supposed to check the value of the column 'average', and get the id from the column where it is less then a certain number. Then, it's supposed use the ID to go into another table to fish out the rest of the fields. Here's a better explanation:
<?php
$db = mysql_connect("localhost","","l");
mysql_select_db("dbthawowi_2",$db);;
$callsign = $HTTP_POST_VARS['id'];
$sql="SELECT id FROM evaluation WHERE average='<1.5'";
$result=mysql_query ($sql, $db);
$secondsql="SELECT id, joke FROM userjokes WHERE id='$sql' AND validation='yes' ORDER BY id";
$secondresult=mysql_query ($sql, $db);
while ($row = mysql_fetch_object ($secondresult))
{
print "<td><a href=\"dump2.php?id=$row->id\" target=\"new\">" . $row->id . "</a>";
}
?>
This gives me a blank page. Can anyone tell me why?
Thanks.