I notice that, the exposed filters text field is case sensitive.
when i enter "france" it return no result because the body content only has the keyword "France" , i'm suggesting that it should be less sensitive on the case itself because when user do a filter search, rarely will use uppercase and therefore the content with uppercase keyword will not be return.
please feel free change the issue category accordingly, either it is a feature request or a bug report
| Comment | File | Size | Author |
|---|---|---|---|
| #2 | views-1.6.x.patch | 1.56 KB | Jhef.Vicedo |
| exposed_filter.JPG | 5.31 KB | Foodster |
Comments
Comment #1
najibx commentedYes, I can confirm this. Looking forward for fixing. BTW, i am using latest Dev version.
Comment #2
Jhef.Vicedo commentedActually, the behavior looks case sensitive but it is not. Try searching for keywords that do not start with "d", "s", "f" and "b". Search works perfectly well.
I think the problem is with the replacement of the placeholders, which are %d, %s, %f and %b, with the actual data when the code reaches the _views_view_build_filters() call inside the _views_build_query() function. The resulting query contains LIKE conditions that are not properly escaped.
Here's the patch that adds extra "%%" in the "contains", "words", "allwords", "ends" and "not" operators.
Comment #3
Jhef.Vicedo commentedComment #4
cghobbs commentedI've tried this patch and so far seems to have fixed the issue and has not created any new ones that I can see.
Comment #5
marcingy commentedI have just encountered this issue and the patch seems to fix the problem with no knock on effects
Comment #6
kehan commentedgot this issue too and the patch applies cleanly and fixes it for me. Any thoughts about applying this to head?
Comment #7
mroswell commentedDoes this patch fix the
"d", "s", "f" and "b"
problem?
Comment #8
ekrispin commentedPatched it and it fixed the problem. Thanks!
Comment #9
merlinofchaos commentedI believe this patch is not necessary in the -dev version of Views 1, where the %d/b/f/s problem is already fixed. Could someone confirm this?
Comment #10
kulfi commentedI can not find a 5.x -dev release? For 5.x1.6:
- I'm getting an error if searching for 'contains' 'b'.
- Also, the exposed filters are case sensitive.
Comment #11
Jhef.Vicedo commented@merlin
I have tested the -dev version and you're right, problem is already fixed. Would there be any new release? thanks,
Comment #12
Matthieu commentedThe patch works well, thanks a lot.
Matthieu
Comment #13
marcingy commentedFixed in dev version
Comment #14
Anonymous (not verified) commentedAutomatically closed -- issue fixed for two weeks with no activity.