by

How to customize the WordPress Login Logo

WordPress uses CSS to display a background image -- the WordPress logo -- in the link (<a>) inside the heading tag (<h1>). 
In this PHP example, the login_enqueue_scripts hook allows to insert CSS into the head of the login page so you can show your logo instead. You can replace the file named logo.png with the file-name of your logo, and store your logo in a directory named /images.

Original link: http://codex.wordpress.org/Customizing_the_Login_Form
Copy Embed Code
<iframe id="embedFrame" style="width:600px; height:300px;"
src="https://www.snip2code.com/Embed/16236/How-to-customize-the-WordPress-Login-Log?startLine=0"></iframe>
Click on the embed code to copy it into your clipboard Width Height
Leave empty to retrieve all the content Start End
function my_login_logo() { ?> <style type="text/css"> body.login div#login h1 a { background-image: url(<?php echo get_bloginfo( 'template_directory' ) ?>/images/logo.png); padding-bottom: 30px; } </style> <?php } add_action( 'login_enqueue_scripts', 'my_login_logo' );
If you want to be updated about similar snippets, Sign in and follow our Channels

blog comments powered by Disqus