Forums › Forums › Search & Filter Pro › Can search work on text displayed on browser, rather than saved id in db?
Tagged: search
- This topic has 3 replies, 2 voices, and was last updated 8 years, 7 months ago by Trevor.
-
Anonymous(Private) April 7, 2016 at 8:40 pm #41992
Hi,
I’m running into an issue with the search box where my content is saved as an id, however, I need to be able to search by the id’s label and have it return results saved with the id that the label name is associated with.So for instance, if a post is written by an employee with employee_id of 5, the post is saved with the metadata: employee_id = 5. When viewing the post on a browser, I can display the employee’s full name by pulling it from a db table with author ids and names. However, is there any possible way to enter the employee’s full name within the search box, and have it return posts with that employee’s id associated with it?
Please let me know when you can, any advice on this would be greatly appreciated! I wanted to save by id in case any names changed, but i’m worried there isn’t a way to get this working the way I’m expecting it to.
Thanks again for all your help!
Trevor(Private) April 8, 2016 at 9:29 am #42027I read this one last night and didn’t understand, but I think I do now. Rather than have an author select box to use for searching, you want the visitor to be able to simply enter the author’s name in a text search field as though the author’s name is part of the post content?
Anonymous(Private) April 8, 2016 at 3:16 pm #42055Hi,
Thanks for the response. Well, we have a search input text box and we need to be able to search by employee name, however, the employee id is the only thing saved to the post (not the full name). So when I enter the employee’s full name in text search, it doesn’t come up in results.Is this possible?
Or do you know if there’s an easy way to save hidden fields with the employee name/label? Might be an ACF hook.
-
AuthorPosts