Closed (fixed)
Project:
Sphinx Search
Version:
5.x-1.1
Component:
Miscellaneous
Priority:
Normal
Category:
Feature request
Assigned:
Unassigned
Reporter:
Created:
4 Sep 2008 at 01:59 UTC
Updated:
2 Jan 2014 at 19:06 UTC
Jump to comment: Most recent
Comments
Comment #1
szy commented... 'rewrite it' - I mean rewrite all previous urls using 'q', remembered
by search engines, bookmarks, etc., to make them working again
with new search index.
Szy.
Comment #2
markus_petrux commentedAt one point I'm planning to implement hook in different places to allow external modules change the behaviour of the sphinxsearch module, but I'm not ready for that yet, as I first would like to add a couple more features (cache sphinx query results and maybe some kind of access control mechanism).
I you need this feature now, then you would have to patch
sphinxsearch.common.inc. However, you cannot use 'q' as it is the query string argument used by Drupal for the site path that is passed to Drupal index.php.Anyway, here's an example on how 'keys' could turned into 'query':
- Function sphinxsearch_get_query_string: Adding something like this before the return statement
- Function sphinxsearch_parse_request: Adding something like this just after definition of the
$search_optionsarray on top of the funcion:However, with those hooks that I'm planning to add in the module, it will be possible for external modules to extend the number of fields indexed, available for advanced search form, faceted search, etc. So if you change the name of query string variables now, those may conflict with other fields added by external modules in the future. ie. the query string used for seaches imposes a single namespace for variables, where collissions are possible and will generate unexpected results.
I'm posting a possible alternative for you with the above example, but you should take care to maintain it, if conflicts occur in the future. ;)
Comment #3
szy commentedYour support is great, thanks, works just like I wanted it.
Szy.