Brute force and redirect non-logged in users
-
Hi there,
I would like to lock the frontend and redirect non-logged in users to the login url. The thing is that there is probably a redirect conflict, when the captcha is enabled and the user can never reach the normal wp-login.php, despite the successful captchas. Here is the redirect:
add_action( 'template_redirect', 'boom_unlogged_users' ); function boom_unlogged_users() { if ( ! is_user_logged_in() ) { wp_safe_redirect( wp_login_url() ); die; } }
I would appreciate any solution to overcome this.
Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
- The topic ‘Brute force and redirect non-logged in users’ is closed to new replies.