WordPress Set Remember Me To Be Checked

You want to Set Remember Me To Be Checked in WordPress Login Page.

To do this follow the following process.

Step One: Open your WordPress web site as an administrator.

Step Two: Then go to the WordPress Dashboard.

Step Three: Then move your mouse pointer and hold on Appearance menu.

Step Four: Then move and click on the Editor sub menu.

Step Five: Then Select theme to edit.

Step Six: Click on the functions.php page (This is your current theme page)

Step Seven: Then place the following code into functions.php page.

 

The code is:

<?php
 
function login_checked_remember_me() {
 add_filter( 'login_footer', 'rememberme_checked' );
}
add_action( 'init', 'login_checked_remember_me' );
 
function rememberme_checked() {
 echo "<script>document.getElementById('rememberme').checked = true;</script>";
}
?>

Leave a Reply