jcadima
3/5/2015 - 5:13 AM

WP admin custom logo without a plugin

WP admin custom logo without a plugin

// make sure to upload logo.png into the theme images folder first
// on functions.php:

function custom_login_logo() {
    echo '<style type="text/css">'.
             '.login h1 a { background-image:url('.get_bloginfo( 'template_directory' ).'/images/logo.png) !important; background-size: contain; width:100%; margin: 0;
padding: 0; }'.
         '</style>';
}
add_action( 'login_head', 'custom_login_logo' );