Skip to content

Latest commit

 

History

History
22 lines (17 loc) · 788 Bytes

79-suppress-s2member-list-until-search-takes-place.md

File metadata and controls

22 lines (17 loc) · 788 Bytes
title categories tags author github-issue
Suppress [s2Member-List /] until search takes place?
questions
s2member-list, shortcodes, mu-plugins-hacks
jaswsinc

I'm using [s2Member-List-Search-Box /] together with [s2Member-List /]. After I press search it displays search results. Is there a way to suppress the list unless and until a search is performed?

Yes, you could use a conditional for this.

  1. Install the ezPHP plugin for WordPress. See: https://wordpress.org/plugins/ezphp/
  2. Use the Text tab in your WordPress editor and add the following conditional PHP tags.
[s2Member-List-Search-Box /]

<?php if(!empty($_REQUEST['s2-s'])): ?>
	[s2Member-List enable_list_search="yes" /]
<?php endif; ?>