this question exact duplicate of: php keyword search engine no results [duplicate] i have simple mysql database keyword search functional. results search not being returned if keywords not in same order entered in database. example searching "dog cat lion" return result, searching "dog lion cat" return no results. on how fix issue appreciated. here code. <!doctype html> <html> <head> <meta charset="utf-8"> <title>part search</title> </head> <body> <?php $username = "xxxx"; $password = "xxxx"; $hostname = "localhost"; //connection database mysql_connect($hostname, $username, $password); mysql_select_db("wesco"); $search = mysql_real_escape_string(trim($_post['searchterm'])); $find_parts = mysql_query("select * `parts` `keywords` '%$search%'"); while($row = mysql_fetch_as...
Comments
Post a Comment