[SOLVED ] Is there any problem with this code??

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
dakkonz
Forum Commoner
Posts: 69
Joined: Sat Dec 27, 2003 2:55 am
Location: Asia

[SOLVED ] Is there any problem with this code??

Post by dakkonz »

Code: Select all

$query = "SELECT * FROM client WHERE MATCH (comName) AGAINST ({$_POSTї'word']})";
            $result1 = @mysql_query ($query);
            $row1 = @mysql_fetch_row($result1);
Can anyone tell me if there is anything wrong with this code??
Last edited by dakkonz on Sat Mar 13, 2004 7:44 am, edited 1 time in total.
User avatar
Pointybeard
Forum Commoner
Posts: 71
Joined: Wed Sep 03, 2003 7:23 pm
Location: Brisbane, AUS
Contact:

Post by Pointybeard »

Are you saying its not working? Get rid of those @ symbols and see what, if any, errors its throwing.

off the top of my head, it looks ok....if i remember correctly, to use the match thingie, you have to have set that field in the table to "full text" otherwise it wont work. Have a look in the manual.

-PB
dakkonz
Forum Commoner
Posts: 69
Joined: Sat Dec 27, 2003 2:55 am
Location: Asia

Post by dakkonz »

thanks a lot.. did not set the field to be FULLTEXT
Post Reply