WordPress.org

Ready to get started?Download WordPress

Forums

How to change the WordPress login page logo link (10 posts)

  1. Sreejesh
    Member
    Posted 2 years ago #

    Hey Pals,

    I was wondering how to change the login page logo link . If anyone is willing to help. It will be highly appreciated!

    Thanks,

  2. esmi
    Theme Diva & Forum Moderator
    Posted 2 years ago #

  3. Sreejesh
    Member
    Posted 2 years ago #

    @Esmi

    Thanks, but I was looking for a code, eliminating the use of a plugin. I know there are lots of plugin which does the job. For me they are too much , or adds up more unwanted functions

  4. esmi
    Theme Diva & Forum Moderator
    Posted 2 years ago #

    That's not possible without editing core - which isn't recommended.

  5. Phil
    Member
    Posted 2 years ago #

    All you need to to do is save an image called wp-logo.png and replace the existing in wp-admin/images.

    You'll need to replace it after every update.

  6. Sreejesh
    Member
    Posted 2 years ago #

    But you see, I'm already using some code in the functions.php to change the login page logo. So I was wondering if there is any such code to change the link of the logo.

  7. Sreejesh
    Member
    Posted 2 years ago #

    This is the code I'm using right now. But this only changes the logo, not the link.

    add_action("login_head", "my_login_head");
    function my_login_head() {
    	echo "
    	<style>
    	body.login #login h1 a {
    		background: url('".get_bloginfo('template_url')."/images/logo-login.gif') no-repeat scroll center top transparent;
    		height: 90px;
    		width: 400px;
    	}
    	</style>
    	";
    }
  8. brasofilo
    Member
    Posted 2 years ago #

    @srj
    this is the code:

    function loginpage_custom_link() {
    	return 'http://domain.com';
    }
    add_filter('login_headerurl','loginpage_custom_link');

    and this one will change the tooltip when you rollover the logo:

    function change_title_on_logo() {
    	return 'My Tooltip';
    }
    add_filter('login_headertitle', 'change_title_on_logo');
  9. Sreejesh
    Member
    Posted 2 years ago #

    @Brasofilo

    Thanks for the quick reply and I tried it and it works!

    Bravo!!

    Thanks again

  10. brasofilo
    Member
    Posted 2 years ago #

    cool, srj :)

    @forum moderators
    does anybody has permissions to edit other's posts?
    my previous post in this thread has been edited, and not by me.

    i said Esmi shouldn't categorically say something is not possible if not sure/not know
    it wasn't an ad hominen attack nor lacking politeness

    if someone can edit my posts, probably they can be deleted too...

    let's what happens with this one...

Topic Closed

This topic has been closed to new replies.

About this Topic