I figured out how, it's pretty simple actually. You can either have it as part of the Update DB subroutine, or you can make a separate button "Clean DB".
Basically all it does is run an SQL query and delete any row where the search text is empty:
mysql_query("DELETE FROM `search_queries_sorted` WHERE search_text = ''");
Additionally you can have it remove other searches, such as "test" and "testing" (diagnostic searches).
__________________
x-cart v4.0.17 - linux/apache
|