Hi,
Below is a portion of PHP (which works fine), although I need to alter the SQL query so that a row with 1 or more of the words is returned. I think that it only returns rows with all of the words at the moment. Any suggestions would be appreciated.
ThanksPHP Code:$q = stop_sql_inj($_GET[q]);
$q = str_replace(" ","%%%%",$q);
$my_select_001 = mysql_query("SELECT * FROM mytable
WHERE keywords LIKE '%%$q%%'
AND allow = '1' ORDER BY RAND() LIMIT 1");
![]()




Bookmarks