Hi especially to Dereck
If you visit www.adultinfo4u.co.uk/new/index.php and goto the 'look for an escort' link then when the menu opens out u will see a list of areas I have added this to the link
display.php?location=london
that should then pass the arguments through to the display.php page the code below
<?php
include "common.php";
$link = mysql_connect("$server", "$username", "$password")
or die("Could not connect");
mysql_select_db("$db") or die("Could not select database");
if (empty($page)) $page = "";
if (empty($search)) $search = "";
if ($page == search) {
if ($search == 1) {
$result = mysql_query("SELECT * FROM user WHERE location = '$location'");
}
echo "Bad Search";
}
echo "<table align=center><tr><td><font face=arial size=2>Escort</td><td><font face=arial size=2></td><td><font face=arial size=2>City</td><td><font face=arial size=2>Age</td></tr>";
(line 15) while ($i = mysql_fetch_array($result)) {
echo "<tr><td><font face=arial size=2><a href=view.php?id=".$i[id].">".$i[user]."</a></td><td><font face=arial size=2>".$i[location]."</td><td><font face=arial size=2>".$i[city]."</td><td><font face=arial size=2>".$i[age]."</td></tr>";
}
echo "</table>";
?>
but once clicked I am getting the following error why is this?
Warning: Supplied argument is not a valid MySQL result resource.....at line 15
Thanks
Aaron