Hello i'm new and i'm working on a simple web site,but the php just doesn't work properly...could you find the mistake in this code?
<html>
<head>
<title>Select</title>
</head>
<body>
<?php
$host='localhost';
$user='root';
$password='root';
$database='tesina';
$db=mysql_connect($host,$user,$password)
or die ("errore");
mysql_select_db($database,$db)
or die("manca il database");
$query="select * from a_ricerca";
$risultato=mysql_query($query,$db);
print "<table border=\"1\">\n";
print "<tr><td><b>ID</b></td><td><b>Nazione</b></td><td><b>Localita'</b></td><td><b>Cost</b></td><td><b>Data di partenza</b></td><td><b>Data di ritorno</b></td></tr>";
while($line=mysql_fetch_array($risultato, MYSQL_NUM)){
print "\t<tr>\n";
foreach($line as $col_value){
print "\t\t<td>$col_value </td>\n";
}
print "\t</tr>\n";
}
print "</table>";
mysql_free_result($dbResult);
?>
</body>
</html>
It gives to me this error: Parse error: syntax error, unexpected T_VARIABLE in C:\AppServ\www\joomla\prenotazioni\select_localita.php on line 17
P.S.:Sorry for my english but i'm italian