Unknown modifier - bug?
I put this:
Splitting declaration on materials / labour charges
into a search box and got this:
---
A PHP Error was encountered
Severity: Warning
Message: preg_split() [function.preg-split]: Unknown modifier '|'
Filename: low_search/ext.low_search.php
Line Number: 477
---
A PHP Error was encountered
Severity: Warning
Message: preg_replace() [function.preg-replace]: Unknown modifier '|'
Filename: low_search/ext.low_search.php
Line Number: 548
---
Is this a bug, seem the / character causes a problem?
Thanks
Lee
Replies
Low 24 Mar 2013 11:15
Where exactly are you putting this query? Front-end templates? Find & Replace utility in LS?
And what version of Low Search are you using?
leeaston 24 Mar 2013 11:33
LS 2.2.1. I'm putting the query in front-end templates. Not very pretty, but here's the template:
{exp:low_search:form collection="blog|auto-entrepreneur|sarl-eurl|legal-structure|business-registration|social-financial-help|health-care-carte-vitale|gites-chambres-tables-dhotes|forms|general-discussion" search_mode="all" result_page="search" query="{segment_2}" secure="no" required="keywords"}
{/exp:low_search:form}
-------------------------
Results page:
{exp:low_search:results encode="no" query="{segment_2}" search:title limit="10" paginate="bottom"}
Low 24 Mar 2013 12:20
Indeed, looks like a bug when the forward slash appears in the keywords *and* is highlighted in the excerpt. To fix, open op ext.low_search.php in a text editor and look up this on lines 321 and 322:
Replace those two with these lines:
leeaston 24 Mar 2013 16:13
Thanks Low. Appreciate the help on a Sunday!