Support » Theme: GeneratePress » Custom Search Pages per Categories

  • Resolved f4nt44smarg

    (@f4nt44smarg)


    Hello!
    I’m sorry if the question comes out as totally naive, I’m starting to get the feeling it probably is.. but here we go.
    Is there a way to insert on some pages a search bar that searches only posts within a specific category? (and to display that search results).

    I know I probably phrased it wrong, so I’ll add a little dumb example.
    I have 10 posts, 5 are in the category “fruit” and 5 are in the category “animals”.
    Let’s say I want to find ‘kiwi’ and I look for ‘brown’ in the main search bar: I would get a lot of animals as well (ex. ‘Otter’, ‘Kiwi’, ‘Bear’, whatever).
    Can I have a “search the fruits” page, where you would look for certain terms *only* in the fruit category, etc..?
    Thanks a lot!

Viewing 5 replies - 1 through 5 (of 5 total)
  • Theme Author Tom

    (@edge22)

    Hi there,

    So basically you want to only include search results that are in the same category as the post being viewed when the search is initiated?

    Which search bar are you using? Is it a widget or is in the navigation search?

    Let me know 🙂

    f4nt44smarg

    (@f4nt44smarg)

    Thank you for replying so fast, you really are legendary!
    But probably I wasn’t as clear as I wished. What I would like to do is having multiple searchbars located in different pages and with different settings, so that in the page “Fruits” you would only search posts that have a ‘fruit’ category, in the “Animals” page you would only search posts that have a ‘animal’ category and so on. Now, I realize that I probably need some external plugin for this, and I tried Ivory search, but I’m having trouble setting it up and I’m not sure if it’s because of Generate Press. What I get when I activate the plugin is this: https://imgur.com/a/BoyAcXc
    (to clarify, I am using Generate Press free version, not pro, with a child theme

    f4nt44smarg

    (@f4nt44smarg)

    (by the way, your theme is fantastic, support is fantastic, everything is very easy and I’m learning so much, I’ll probably buy the premium version as soon as I can)

    f4nt44smarg

    (@f4nt44smarg)

    Never mind I think I found a plugin that works wonders and does exactly what I wanted it to do (and goes along well with GP!).

    I’m a little disappointed I had to plugin my way out of this, I was hoping to do it by myself but honestly I couldn’t, I have a lot to learn. Thanks for the support though!

    Theme Author Tom

    (@edge22)

    Glad you found a solution! It sounds quite complex, so I’m not surprised that a plugin was necessary in this case.

    Thank you! Let us know if you have any other questions 🙂

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Custom Search Pages per Categories’ is closed to new replies.