Hi
I created a login form in the frontend with wp_login_form(). In my functions.php I added an action to prevent the redirect to /wp-login.php if the login failed with add_action('wp_login_failed', …
As it turns out the action only hooks if the username AND password fields are filled in. If one of them is left empty I still get redirected to wp-login.php.
Is there a possibility to check if both fields are filled in to prevent the redirect?
Thanks, Julian
wp_authenticate which calls do_action('wp_login_failed'... is a pluggable function (http://codex.wordpress.org/Pluggable_Functions), so you could copy it from pluggable.php to your theme's functions file and modify to suit your needs.
Hi Jackson
Thanks a lot for your reply! Got this to work now and learned something new!
Thanks again
Julian
webladynz
Member
Posted 6 months ago #
I have the same problem, but being new to WP I do not understand how you solved this issue. Your assitance would be most appreciated