Created
June 4, 2014 14:44
-
-
Save mustardBees/f23fea18aebde975d734 to your computer and use it in GitHub Desktop.
WordPress login page tweaks
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Filter the logo on the WordPress login page | |
*/ | |
function iweb_login_logo(){ | |
echo '<style type="text/css">h1 a {background-image:url(' . get_stylesheet_directory_uri() . '/logo.png' . ') !important; background-position: center center !important; background-size: auto !important; width: 265px !important; height: 80px !important;}</style>'; | |
} | |
add_filter( 'login_head', 'iweb_login_logo' ); | |
/** | |
* Filter the url of the logo on the WordPress login page | |
*/ | |
function iweb_login_logo_url( $url ) { | |
return home_url( '/' ); | |
} | |
add_filter( 'login_headerurl', 'iweb_login_logo_url' ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment