Skip Navigation

[Resolved] toolset views – custom search – filters & buttons are hidden (display:none) !

This support ticket is created 3 years ago. There's a good chance that you are reading advice that it now obsolete.

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

Sun Mon Tue Wed Thu Fri Sat
- 9:00 – 12:00 9:00 – 12:00 9:00 – 12:00 9:00 – 12:00 9:00 – 12:00 -
- 13:00 – 18:00 13:00 – 18:00 13:00 – 18:00 14:00 – 18:00 13:00 – 18:00 -

Supporter timezone: America/Jamaica (GMT-05:00)

This topic contains 3 replies, has 2 voices.

Last updated by Shane 3 years ago.

Assisted by: Shane.

Author
Posts
#2260297
Capture d’écran 2022-01-06 à 18.14.08.png
Capture d’écran 2022-01-06 à 18.30.00.png
Capture d’écran 2022-01-06 à 18.37.04.png

Hi,

I was just defining a very simple search on a custom post type called "products".
Each time I try to add a filter and/or a submit button : those are hidden.

the results are visible though. Just the filters and submit button are hidden.
It seems (when inspecting on Chrome) that the html element "form" has a inline style with a display:none;

#2260337

Shane
Supporter

Languages: English (English )

Timezone: America/Jamaica (GMT-05:00)

Hello,

Thank you for getting in touch.

This normally occurs when you've added the view and set it to display only the results. Can you let me know the exact shortcode that you're using to display the view or if you're using blocks ?

Whenever the view is told to display only the search results then the search bar will be hidden. This is generally done by using the shortcode parameter view_display="layout"

Please check your view to ensure that this parameter has not been added to the shortcode.

Thanks,
Shane

#2260817

OK. I removed the 'view_display="layout" ' and now it displays the filters and buttons. ok.

Now two additional related questions because it is still not exactly good :
when we first access the page, all "products" are displayed (a lot), whereas no choice has been made yet concerning the filters and I think I'd prefer not to display any products yet.
(FYI : I am using the good old Toolset Views legacy since when I upgrade to Toolset blocks, some of my shortcodes (conditional, and others are not working anymore) and I'll like to stay as such if possible).
thanks

#2260961

Shane
Supporter

Languages: English (English )

Timezone: America/Jamaica (GMT-05:00)

Hello,

You can do this by using our Conditional shortcode to hide the results.
Wrap your view output information inside this shortcode

[wpv-conditional if="('[wpv-search-term param='wpv_view_count']' ne '' )" ]
<wpv-loop>
My loop content here
</wpv-loop>
[/wpv-conditional]

Please let me know if thi shelps..
Thanks,
Shane