Hello, good morning! I am having a problem and I am not finding the variable to solve it, I have a site in WP and when I try to login and neither the password nor the email exists, I get the error message: ERROR: The username or password you entered is incorrect Lost your password? I tried to find this phrase in wp-login.php but I did not find it, could you help me? Note: I tried to use the loco translate but he does not think that phrase!
Edit the test I'm trying to make the messages appear only on the login page.
functions.php
function erroLogin(){
add_filter( 'login_errors', 'rs_custom_login_error' );
function rs_custom_login_error(){
return $error = "Informações não existem ou estão erradas!";
}
}
page.php
<?php if ( is_page( 'login' ) ) { ?>
<?php erroLogin(); ?>
<?php } ?>
And I tried it that way too.
functions.php
<?php if ( is_page( 'login' ) ) { ?>
add_filter( 'login_errors', 'rs_custom_login_error' );
function rs_custom_login_error(){
return $error = "Informações não existem ou estão erradas!";
}
}
But it still did not work