Enter your keyword

Blog

How to add default avatar in Wordpress

function wp_addgravatar($avatar_defaults){
$myavatar = get_template_directory_uri() . '/images/avatar.png';
$avatar_defaults[$myavatar] = 'avatar';
return $avatar_defaults;
}
add_filter( 'avatar_defaults', 'wp_addgravatar' );

No Comments

Add your review

Your email address will not be published.

* Feilds are Required.