plugin not working with front-end login
-
Hi,
We were using the plugin with a front-end login. Everything was set NOT to get de default login page after filling in wrong credentials. But now after the update, people are redirected to the custom login page after giving no credentials or false credentials.Plugin is installed on a multisite with the members plugin active. Was working fine on the old version.
We like to keep the people on the front-end.
What can we do to get it as it were, without installing an older version of the plugin. How do we keep people on the front-end
We have tried with making a loginform with custom coding and with the login widget which comes with the members plugin. I tried several codes to keep people front end but nothing is working.This is one of the snippets I used in my functions.php.
It worked before, but isn’t anymore:
add_action( ‘wp_login_failed’, ‘vvg_login_fail’ ); // hook failed login
function vvg_login_fail( $username ) {
$referrer = $_SERVER[‘HTTP_REFERER’]; // where did the post submission come from?
// if there’s a valid referrer, and it’s not the default log-in screen
if ( !empty($referrer) && !strstr($referrer,’wp-login’) && !strstr($referrer,’wp-admin’) ) {
wp_redirect(home_url() . ‘/?login=failed’ ); // let’s append some information (login=failed) to the URL for the theme to use
exit;
}
}Hope you can help out.
cheers
Karin
- The topic ‘plugin not working with front-end login’ is closed to new replies.