I have created many Elementor templates in this site already, so in the same flow, I tought I'd set the "Search Results" in the Elementor conditionals for that template, but that didn't work.
I read in the forum I have to create a WordPress Archive via Toolset. Then I linked it to an existing Content Template. That kinda works, hidden link
It would be great though if that page would follow the layout from an Elementor template. Is that possible? Can I somehow insert that WP Archive in a template? Or a View that holds the search results?
Hi,
Thank you for contacting us and I'd be happy to assist.
From your description and looking into the markup of the search results archive, I understand that the layout is being controlled by Toolset, and the inner search result items are shown through the Elementor.
If your goal is to control this search archive completely through the Elementor, you can unassign the archive created through the Toolset and use the Elementor's theme builder option for creating this archive:
hidden link
regards,
Waqar
The issue is, when I don't use Elementor to style the Search Archive, then the layout comes from our Astra theme and that layout is not in line with the rest of our site.
So I prefer to use the Elementor template, but then I don't get the appropriate View to work. I don't know how to adapt the Query filter so it filters the items based on the default WordPress filter parameter "?s=xyz"
I have tried to replicate the Elementor Search Form with CSS, which took a lot of work 🙁
You can see both in the header now hidden link
I just can't seem to get it to work :'(
Thank you for sharing this update.
I'm not completely sure exactly which part is not working. Can you please share some more details?
A quick screencast or screenshots would make it more clear.
Sure, I'll try to explain the issue better.
I am happy to use the included WP search function and happy to use the Elementor Search Widget.
However, I have created a nice Toolset Content Template to display the Woo products grid (the one with the orange add to cart circle) so I wish to use that Content Template to display the WP Search Results.
I have created a Toolset View "Search Results" but that one totally ignores the WP search parameter in the url 🙁
hidden link so it just shows all products, but it does use the correct Content Template. So I I could correctly filter that View based on the search parameter, all would be good.
I have recreated the Elementor Widget in Toolset, but the form action goes to hidden link which does not load my View "Search Results".
I tried to access the website's admin area through the access link from your other ticket. But looks like it has expired.
The WordPress default search archive is accessible at:
{yourwebsite.com}/?s=arran
If you'd like to use the Toolset content template for this search archive, you can go to WP Admin -> Toolset -> WordPress Archives and create a new archive for the search page. For the loop item of this archive, you can use the already-built template.
This way the search results on this link will be shown using that template.
I have extended the WP login link.
1/ I have set the condition of the Elementor template to Search Results.
2/ I have entered this HTML code "[wpv-post-body view_template="loop-item-in-products-filter"]"
Search results are not ok
hidden link should show at least 3 items.
hidden link should show at least 7 items.
I see the difference in the number of results showing in the search on the dev website and the live one.
But I don't have access to the admin area of the dev website. The access link for the dev website works, thank you.
Can you please also share the access details for the dev website as well? I'm setting your next reply as private.
I've read your other ticket and was able to access the admin area of the dev website using the old link.
The way the Elementor template for search is working, I understand that it is showing only the first search result and not looping through all of them.
Why not unassign this 'Search Results' archive template from Elementor and instead create it through Toolset, as I suggested in earlier?
( WP Admin -> Toolset -> WordPress Archives )
It will allow you to use your desired content template [wpv-post-body view_template="loop-item-in-products-filter"] in the loop.
In case you'll prefer to use the search archive from the Elementor, you can consult its support or documentation, to understand how it can be made to loop through the search results instead of showing just one.
DEV:
1/ I have used the shortcode [wpv-post-body view_template="loop-item-in-products-filter"] in the Elementor Search Results template, maybe that is why it only shows 1 item? But even if it showed all the results, the styling is still a bit off, because I am missing some div classes from the View (I am only using the Content Template).
2/ I have then deleted the Elementor condition from the template so it is no longer in use, then I get all the expected search results, but without styling. See the header "zoekresultaten voor: xxx" missing from screenshot 2.
3/ I have then created a WP Archive via Toolset and copied over the content of the loop editor from my Products Filter View. This is approaching the desired result the most, except I am missing the search results header with the Search Term and the page width is no longer conform my Elementor settings. But maybe I could work from here and add the required Elementor divs/classes/
Thank you for sharing this update.
Yes, option 3, does seem to be the most appropriate option and it will give you the most flexibility and design control.
Please let me know if you have any follow-up question and for a new question or concern you're welcome to start a new ticket.
I have almost achieved what I was looking for, but it's good enough 🙂