Im working on my website and i want a to have a search engine using full text search im using phpmyadmin heres my code
<?
$username="root";
$password="";
$database="mydata";
$search=$_POST['search'];
mysql_connect(localhost,$username,$password);
@mysql_select_db($database) or die( "Unable to select database");
$query = "SELECT name, age, address, zip, phone FROM member WHERE MATCH(name, age, address, zip, phone) AGAINST ('$search')";
$result=mysql_query($query);
$num=mysql_numrows($result);
mysql_close();
echo "<b><center>Database Output</center></b><br><br>";
$i=0;
while ($i < $num) {
$search=mysql_result($result,$i,"name");
echo "Name:<b>$search<hr><br>";
$i++;
}
?>
first problem it gives warning and second it doesnt give any results can u pls tell me whats wrong. all of my fields in the database were set to FULL TEXT INDEX