View Single Post
Old October 21st, 2005, 10:14 PM   #4 (permalink)
Michael P
PhotoPost Developer
Verified Customer
 
Join Date: Jan 2002
Posts: 11,858
Quote:
$keyphrase .= "((title LIKE \"% $key%\" OR description LIKE \"% $key%\" OR keywords LIKE \"% $key%\" OR bigimage LIKE \"% $key%\"
OR extra1 LIKE \"% $key%\" OR extra2 LIKE \"% $key%\" OR extra3 LIKE \"% $key%\" OR extra4 LIKE \"% $key%\" OR extra5 LIKE \"% $key%\" OR extra6 LIKE \"% $key%\")";
$keyphrase .= " OR (title LIKE \"$key%\" OR description LIKE \"$key%\" OR keywords LIKE \"$key%\" OR bigimage LIKE \"$key%\"
OR extra1 LIKE \"%$key%\" OR extra2 LIKE \"%$key%\" OR extra3 LIKE \"%$key%\" OR extra4 LIKE \"%$key%\" OR extra5 LIKE \"%$key%\" OR extra6 LIKE \"%$key%\"))";
As you can read from the code snippet above, we look for:

- Words that start with the keyword in all fields
- Words that end in a keyword (title, description, keywords, bigimage)
- Patterns that appear with extra fields (can be contained within the string)

If there are better ways, I am open to suggestions.
__________________
Please do not PM me for support or sales questions. Thank you for your understanding.
Michael P is offline   Reply With Quote