Extracted search function cxense_search() from ajax-search