Answers.Body: <p>This problem turned out to be a Javascript error in the console:</p>
  
  <p><code>SyntaxError: expected expression, got '&lt;' on civicrm:1</code></p>
  
  <p>A plugin must have been dumping in Javascript in the header or footer, and once it was deactivated, CiviCRM could render the search results in Javascript.</p>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2019-11-12T17:32:47.550Z
Answers.LastActivityDate: 2019-11-12T17:32:47.550Z
Answers.UserDisplayName: BlueDogRanch
Body: <p>This is a fairly broad question: a client wants to have a publicly searchable member directory. So I'm looking at some old questions, such as <a href="https://civicrm.stackexchange.com/questions/2264/creating-a-public-members-directory-with-civicrm-in-wordpress-using-profiles">Creating a public Members directory with CiviCRM in Wordpress using Profiles</a> and <a href="https://civicrm.stackexchange.com/questions/6650/creating-a-public-members-directory-with-civicrm-in-wordpress-using-profiles-and">Creating a public Members directory with CiviCRM in Wordpress using Profiles and shortcode</a> with no luck.</p>
  
  <p>Is there a shortcode for a publicly (not as member and not logged in) searchable member directory? <em>(I have told the client this has privacy implications.)</em></p>
  
  <p>This is currently being used but returns no results:</p>
  
  <p><code>[civicrm component="profile" gid="11" mode="search" hijack="0"]</code></p>
  
  <p><a href="https://i.sstatic.net/drMkF.png" rel="nofollow noreferrer"><img src="https://i.sstatic.net/drMkF.png" alt="enter image description here"></a></p>
  
  <p>But not showing search results may be a result of no permissions for the anonymous user, as I read in one of the linked questions. I've given anonymous users the capabilities for profile listings and forms and profile listings in Administer >  WordPress Access Control. I've set up a Smart Group and a profile, outlined on <a href="https://docs.civicrm.org/user/en/latest/organising-your-data/profiles/" rel="nofollow noreferrer">https://docs.civicrm.org/user/en/latest/organising-your-data/profiles/</a> . But that doesn't help.</p>
  
  <p>Using:
  WP 5.2.4
  CiviCRM 5.17.5</p>
  
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2019-11-12T14:33:25.840Z
Comments.Text: Does it return results for a logged in user?
Comments.UserDisplayName: Graham
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2019-11-12T15:12:30.570Z
Comments.Text: No results for logged in users.
Comments.UserDisplayName: BlueDogRanch
Tags: <wordpress><civimember><search>
Title: Shortcode and permissions for WordPress publicly searchable member directory
ThreadText: # Shortcode and permissions for WordPress publicly searchable member directory
  
  (Asked by: username_0 on 2019-11-11)
  
  This is a fairly broad question: a client wants to have a publicly searchable member directory. So I'm looking at some old questions, such as [Creating a public Members directory with CiviCRM in Wordpress using Profiles](https://civicrm.stackexchange.com/questions/2264/creating-a-public-members-directory-with-civicrm-in-wordpress-using-profiles) and [Creating a public Members directory with CiviCRM in Wordpress using Profiles and shortcode](https://civicrm.stackexchange.com/questions/6650/creating-a-public-members-directory-with-civicrm-in-wordpress-using-profiles-and) with no luck.
  
  Is there a shortcode for a publicly (not as member and not logged in) searchable member directory? *(I have told the client this has privacy implications.)*
  
  This is currently being used but returns no results:
  
  `[civicrm component="profile" gid="11" mode="search" hijack="0"]`
  
  [![enter image description here](https://i.sstatic.net/drMkF.png)](https://i.sstatic.net/drMkF.png)
  
  But not showing search results may be a result of no permissions for the anonymous user, as I read in one of the linked questions. I've given anonymous users the capabilities for profile listings and forms and profile listings in Administer > WordPress Access Control. I've set up a Smart Group and a profile, outlined on <https://docs.civicrm.org/user/en/latest/organising-your-data/profiles/> . But that doesn't help.
  
  Using:
  WP 5.2.4
  CiviCRM 5.17.5
  
  **Tags:** wordpress, civimember, search
  
  > **Comments:**
  > **username_1**: Does it return results for a logged in user?  
  > **username_0**: No results for logged in users.  
  
  ---
  
  ## 1 answers
  
  ### Answer by username_0 on 2019-11-12. Score: 2
  
  This problem turned out to be a Javascript error in the console:
  
  `SyntaxError: expected expression, got '<' on civicrm:1`
  
  A plugin must have been dumping in Javascript in the header or footer, and once it was deactivated, CiviCRM could render the search results in Javascript.
  
  
  ---
  
  