Quantcast
Viewing all articles
Browse latest Browse all 20145

Reply To: [Waiting for user confirmation] Change search result template for a single type

Hi luoy,

Maybe I'm misunderstanding… I want to use the template contained in my theme for everything but a single content type. How would I use that conditional to call the normal search results template if said search result isn't one of my content types?

Here's my use-case: I'm building a tours site where the tours are just listed on a page and don't have an actual link to go to. Using this works fine:

wpv-if evaluate="'[wpv-post-type]' = 'tour'"]MY TOUR RESULT TEMPLATE HERE[/wpv-if]

However, if I have a blog entry that also comes up in a search, I need to pull my theme's default search template instead, right? I don't understand how to do that short of copy/pasting it from my theme into the other conditional in that view, but then it'd break if something with the theme changed or I switched to a new one. Where would I even find my theme's default search template?

Hopefully this makes sense – It's almost time to go home and my brain has already clocked out Image may be NSFW.
Clik here to view.
:P

Thanks for your patience.


Viewing all articles
Browse latest Browse all 20145

Trending Articles