Google Custom Search
ExpressionEngine 2, ExpressionEngine 3, ExpressionEngine 4
Back to this add-on's main page
View Other Add-ons From Derek Hogue
Using colon in search terms
General
ejaeDesign
|
Posted: 04 May 2018 05:14 AM |
|
|
|
Hi Derek,
On our test site, using a term with a colon (“Matthew 5:5” for example) only returns a single result:
https://dev.theologyofwork.org/about
Using regular GSE (not via Google Custom Search add-on), it returns a much wider set of results:
http://www.theologyofwork.org/test
Why are the results different?
Thanks!
|
|
|
Derek Hogue
|
Posted: 04 May 2018 09:51 AM |
# 1
|
|
Developer
|
Try this - open mod.google_custom_search.php, and on line 200 change:
$args['q'] = urlencode($keywords);
to
$args['q'] = $keywords;
And give it another try?
|
|
|
ejaeDesign
|
Posted: 08 May 2018 05:25 AM |
# 2
|
|
|
Thanks, Derek. That did the trick.
Another question for you. Can we use GCS add-on to simply bypass the string query in the URL (generated by default GSE)? For example:
https://dev.theologyofwork.org/search/some-segment/?search=my-search-term
There’s probably a workaround but having a hard time getting it to work with .htaccess + CE Cache,
Much appreciated!
|
|
|
Derek Hogue
|
Posted: 08 May 2018 10:21 AM |
# 3
|
|
Developer
|
Glad that worked. There’s no option to leave the search terms unencoded I’m afraid - there were too many issues using query strings with different EE setups.
|
|
|
petenice
|
Posted: 08 February 2019 03:08 PM |
# 4
|
|
|
Thanks you for that, it worked for me as well
|
|
|