Personally, I am sick and tired of the United States government meddling more and more in our lives. The movie and music industry is using our elected officials like puppets (muppets) and we are sitting idly by and letting it happen. Well, I signed the petition, and my voice will be heard next election. G.R.I.P. – Get Rid of Incumbent Politicians. If we really want to make changes, we have to get those that pander to big business out of office and let them know that we have the power to do it. After all, they are there to represent Read More…
Add a Custom Logo to the WordPress Login Screen
Date: August 13th, 2010
Author: Joe DiFiglia
Category: Wordpress
Tags: functions.php, Wordpress
Article URL: http://computingondemand.com/?p=4133
There are many things about WordPress that make life easy... and a few that are a real pain in the butt. One of the pains is the login form's logo and url. If you are like me, you want to brand your sites and doing so gives the site that extra touch of personalization. Not to mention, if you are designing a site for a customer, you don't want a big fat logo for WordPress linking to the WordPress.org site on the login form.
By simply overwriting the logo-login image in your WordPress wp-admin/images/ folder you risk having the original WordPress image restored every time you update your installation.
The bad news is that there is no way to do this from your WordPress dashboard, the good news is that you can do this easily by editing your theme's functions.php file.
1. create an image with the dimensions 326 wide by 67 high, name it logo-login.gif and drop it into your theme's images folder.
1. edit your functions.php file and add the following code between the <?php and ?>
// --------------------------------------------------------------------------
// Start Custom Login Logo
// --------------------------------------------------------------------------
function my_custom_login_logo() {
echo '';
}
add_action('login_head', 'my_custom_login_logo');
// --------------------------------------------------------------------------
// End Custom Login Logo
// --------------------------------------------------------------------------
// --------------------------------------------------------------------------
// Start Custom Login Logo URL
// --------------------------------------------------------------------------
function change_wp_login_url() {
echo bloginfo('url');
}
function change_wp_login_title() {
echo get_option('blogname');
}
add_filter('login_headerurl', 'change_wp_login_url');
add_filter('login_headertitle', 'change_wp_login_title');
// --------------------------------------------------------------------------
// End Custom Login Logo URL
// --------------------------------------------------------------------------Note: These functions are not of my own creation, simply things I have found along the way. If you are the author of this function, please let me know so I can properly credit you with your work!


