login logo设定代码

将以下代码添加至模板目录下 function.php文件末尾即可。

/*custom logo*/
function custom_loginlogo() {
echo ‘<style type=”text/css”> h1 a {background-image: url(‘.get_bloginfo(‘template_directory’).’/images/logo_login.png) !important; } </style>’;
}
add_action(‘login_head’, ‘custom_loginlogo’);

function custom_loginlogo_url($url) {
return ‘http://bearboyfff.tk’; //在此输入你需要链接到的URL地址
}
add_filter( ‘login_headerurl’, ‘custom_loginlogo_url’ );

Leave a Reply

Your email address will not be published. Required fields are marked *