Hi,
WordPress code is an open source so any one can customize it with desired requirement. I have done some experiment to add image in register/site admin link and I had done it successfully. To replace register/Site Admin with desired image copy this code and add it in functions.php file of your theme:
function ax_register() {
$before = ‘<li>’;
$after = ‘</li>’;
$theme_url = get_bloginfo(‘template_url’);
if ( ! is_user_logged_in() ) {
if ( get_option(‘users_can_register’) )
$link = $before . ‘<a href=”‘ . site_url(‘wp-login.php?action=register’, ‘login’) . ‘”>’ . ‘<img src=”‘ . $theme_url . ‘/images/register.png” alt=”Register” />’ . ‘</a>’ . $after;
} else {
$link = $before . ‘<a href=”‘ . admin_url() . ‘”>’ . ‘<img src=”‘ .$theme_url . ‘/images/site_admin.png” alt=”Site Admin” />’ . ‘</a>’ . $after;
}
echo apply_filters(‘register’, $link);
}
Now, pick two desired images and name it to register.png and site_admin.png. Upload them in images folder of the theme. Now, clear the cache and have a check with your blog login/logout link.
This function will override the output of register filter, it requires you to have wp_register(); somewhere in the theme.
Thanks,
Shane G.
Popularity: 1%