Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /**
- * Function redirects non-logged users to login page
- *
- * @return false
- */
- function login_redirect()
- {
- global $pagenow;
- if( !is_user_logged_in() && ($pagenow != 'wp-login.php') ) auth_redirect();
- return false;
- }
Advertisement
Add Comment
Please, Sign In to add comment