Displaying x most recent posts on a Search Results page

I’ve created a Search results page. The results appear fine on the left, but I’d also like to separately include the x most current posts on the right column of the same page.

I’ve tried a couple of ways, but they just bring up articles that match the same search term.

Any ideas?

The display order of the results is a Wordpress setting/function and not bricks.

I don’t think I’ve been clear enough - I’ll give it another go to try and explain it better :slightly_smiling_face:

The main search results come back fine (as you say, their order dictated by Wordpress).

On the same page I have a widget to show the latest posts on the site - it’s this that is incorrectly showing the latest x posts that match the search criteria, not the latest x posts on the site as you’d expect (irrespective of any search criteria).

Hmmm, I tried to recreate this on a Try site.
Out of the box I got the same issue. I see the same posts as the Results selection.
I was thinking that the CSS ID or query id might need changing but when I went back to the page it is trashed! I’ve lost the entries I’d made, a lot of styling and now the Structure panel shows nothing at all. I am unable to edit the one remaining entry on the page ( a Heading ). So far it is not recovering so can’t help - sorry.

Yikes @alanj

Thanks for trying it out. Sounds like it broke pretty thoroughly!

Hi @flimflam .
Maybe you can try this:
Create a section template with desired content. Use that template with the Template element on the Search results page.

1 Like

Good approach, but unfortunately the result is the same @tole011 :frowning:
The query_vars are shared between the search results and the other posts element, no matter what you set in the query settings of both post elements.

@luistinygod
I’m not sure if this is a bug or a feature request… but generally speaking it should be possible to show other posts on the search results page in additon to the search results.

1 Like

I’ve tried it on test site with couple products (woocommerce) I’m using Relevanssi for search. When a search result is empty, products on the Template element are shown.


Hope we’ll find a solution… :slight_smile:

For the default search posts element + a second posts element it shows “no posts found” in both :frowning: