Search entry_id and number
Hi Low!
I have one input for user type: keywords or number.
If user type number only I want Low Search understand will search entry_id.
I've tried but seem Low Search can't search number, it results all entries.
Thank Low!
Replies
ngoncom 27 Apr 2016 06:43
Hi,
I find out a way to solve this:
I using php regex to check keywords to know it is text or number, if it is number I show entry_id = number.
I enable php (input) and using this code:
Thank!
Low 27 Apr 2016 10:08
I guess that's one way of doing it. Slightly safer would be to create an extension that sets the keywords="" or entry_id="" parameter based on the same principle.