Skip to content

Instantly share code, notes, and snippets.



Last active Sep 1, 2019
What would you like to do?
WordPress redirect non-logged in user to a page/site
// put this in header.php
if (!is_user_logged_in()) {
wp_redirect( '');
} ?>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.