Support » Plugin: WP-Members Membership Plugin » How to block search engine results for non registered users?

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Author Chad Butler

    (@cbutlerjr)

    You would probably need to customize your template that is used for search results. Where the loop is displayed, you could create a condition for user login:

    <?php
    
    if( is_user_logged_in() ) {
    
         // user is logged in - normal Loop code here
    
    } else {
    
         // user is not logged in, display message or you could
         // you could display the wp-members login like this:
    
         echo do_shortcode('[wp-members page="login"]');
    
    } ?>

    Resolved!!!!
    Thank you so much :-))))

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘How to block search engine results for non registered users?’ is closed to new replies.