This topic is locked

Changing the query used in the AJAX autosuggest search

9/24/2008 9:50:34 AM
PHPRunner General questions
M
mattd1 author

The system I am developing is intended to run for multiple clients and data sensitivity is critical. I like the autosuggest feature BUT unfortunately it presently offers other clients' data as it is not limiting to values based on the "clientid" ...
Is there a (an easy) way to modify the query it uses? The "clientid" is carried in a session variable from log on as $_SESSION["cid"] - any way to auto add this "AND cid=".$_SESSION["cid"] in to the autosuggest?
Thanks.
Matt

Sergey Kornilov admin 9/24/2008

You need to modify <table_name>_searchsuggest.php page for this purpose. This is the place where "suggest" SQL queries are constructed and executed.