Tips / Recommendations

Displaying pages only to authorized users wordpress

function prefix_redirect_function() {
if ( is_page(552 , 554) && !is_user_logged_in() ) { // 42 это ID
// редирект на главную:        wp_redirect( home_url() );
// или так на url:
// wp_redirect( ‘http://www.example.com’, 301 );exit;
    }
}
.page-id-296 .zip-check {display:none}

Leave a Reply

Your email address will not be published. Required fields are marked *

1 × 1 =