Further desciption of search system in PHP-eSeller templates

If you use PHP-eSeller and use the template system, the following describes the search function in a bit more detail.

The search system in the templates use the mySQL FULLTEXT search using the MATCH keyword.

The fields that are searched are in tblitems and are item_name, item_title, item_description, item_description_full and keywords

First, all MySQL stop words are ignored in the keyword phrase used in a search. Stopwords are commonly used words that generally do not add anything useful to a search phrase.

Second, alphabetic character case is ignored in a MySQL search, so you do not have to convert anything to all upper or lower case in order to search.

Third, any word found in more than 50% of the rows in the index will be ignored when you use the text search.

Fourth, the results will be automatically sorted by relevancy, so the more times the search words appear in a row in the index, the more relevant that particular entry will be.

Fifth, remember that MySQL does not index any words that are 3 or less characters in length, so very short words are ignored.

Sixth, hyphenated words are treated as separate words.

The important point is probably the third. What this means is that if you have 100 rows where each row has the word ‘computer’ in it, and you do a search for the word ‘computer’, you will get zero result. This is because the search term is not specific enough and hence is unable to return specific rows.

Leave a Reply