Last active
December 12, 2015 07:28
-
-
Save spearsmarketing/4736622 to your computer and use it in GitHub Desktop.
WordPress custom login logo code.
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
// Change login logo | |
add_action('login_head', 'rgt_custom_dashboard_logo'); | |
function rgt_custom_dashboard_logo() { | |
echo '<style type="text/css"> | |
.login h1 a { | |
background-image:url('.get_stylesheet_directory_uri().'/images/logo.png) !important; | |
background-size: 215px 138px !important; | |
width: 215px !important; | |
height: 138px !important; | |
} | |
</style>'; | |
} | |
// Change login link | |
add_filter('login_headerurl','loginpage_custom_link'); | |
function loginpage_custom_link() { | |
return get_site_url(); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment