Comments

Add a Comment

    1. add_filter( ‘login_head’, function () {
      $custom_logo = ‘https://wpcode.com/wp-admin/images/wordpress-logo.svg’;
      $logo_width = 84;
      $logo_height = 84;

      printf(
      ‘.login h1 a {background-image:url(%1$s) !important; margin:0 auto; width: %2$spx; height: %3$spx; background-size: 100%%;}’,
      $custom_logo,
      $logo_width,
      $logo_height
      );
      }, 990 );

      add_filter( ‘login_headerurl’, function () {
      // Update this URL to the desired link when the logo is clicked
      return ‘https://yourcustomurl.com’;
      });

      1. Hi Serkan,

        Thank you for sharing this. We have a suggestion, if you don’t mind: Instead of adding the code here in a comment, can you please create a copy of this snippet using the Duplicate button on the top right and edit that with your suggestion? That way, it’s easier to share your version of the snippet.