Is there a way to change the WordPress logo from the login page?
Hey webconceptplusinc,
Please see the WordPress documentation here: Customizing the Login Form
But there are plugins that are easy to use, like Custom Login Page Customizer, and many others.
Best regards,
Mike
Thanks, i was able to modify with this code in function.php. But i was wondering, if the theme get update, will it replace the function.php file?
/* Replace wp-login logo */
function login_page_logo(){
$site_url = home_url(); // URL of site
echo ‘<style>.login h1 a {
background-repeat: no-repeat;
background-image: url( ‘ . $site_url . ‘/wp-content/uploads/2024/01/U-NEXT-logo-noir-transparent-300×137.png );
background-position: center center;
background-size: contain !important;
width: 100% !important;
}
</style>’;
}
add_action(‘login_head’, ‘login_page_logo’);
/* Replace wp-logo link */
function login_page_URL( $url ){
$url = home_url(‘/home’);
return $url;
}
add_filter(‘login_headerurl’, ‘login_page_URL’);
Hi,
Please consider using a child theme, any changes that do to core parent theme files will be overwritten on updates.
Best regards,
Rikard