I'm working to implement search functionality for a client's website, which has many pages and two blogs. My goal is to create a search input that, when used, returns results from just one of the blogs. Currently, my search input looks like this, adapted from the search_input module:
With this, I have limited the search results to blog posts, but how can I limit it further to just ONE blog? I am definitely in over my head, so any ideas would be appreciated.
You can try appending a &pathPrefix= to the form action something like this below that will only filter anything in that one blog if its something like domain.com/blog2/blog-post-name. I've done this cloning the hubspot search module but they also included javascript that you need to also include the pathPrefix as well. Not sure if you have JS in your module or if this is in your blog listing code.
This is a great help for what I'm looking for. But, the suggestions dropdown doesn't seem to work for me, when I start typing in the input field. They should be appended to the '.hs-search-field__suggestions' element (according to the JS).