I. Past Solutions
Before the Gravatar is not fully coordinated, you can modify the WordPress call Avatar Server resolution, and now invalid. Slow, can be cached avatar, now also invalid. The other is to close the avatar, but for the site needs to display the avatar, a bit regrettable. So these methods are not perfect. The following method is provided by the plugin to solve.
Second, WP User avatar plugin to solve the avatar problem
WP User Avatar This plugin allows users to use images from the Media Library as avatars, while providing the ability to turn off Gravatar. This is a free plug-in, you can in the WordPress background plug-in search for installation. The following author uses the Chinese version of this site to explain the use of the version.
1, first install WP User AVATAR and activate this plugin.
You will see an avatar menu in the WordPress menu. Then click Set:
2, set WP User AVATAR
First we want to close the Gravatar avatar, and check the display avatar, if you allow contributors and subscribers to upload Avatar, also check. After checking, you will also be allowed to upload avatar size settings. Such as:
3. How users upload their avatar
In the background point user-my profile, then you can see the upload avatar.
Third, the Gravatar server was wall, you can change to say, open the functions.php file, copy the following code to the top of the file, note after the first <?php
Say more official Gravatar Avatar call
function Mytheme_get_avatar ($avatar) {
$avatar = Str_replace (Array ("www.gravatar.com", "0.gravatar.com", "1.gravatar.com", "2.gravatar.com"), " Gravatar.duoshuo.com ", $avatar);
return $avatar;
}
Add_filter (' Get_avatar ', ' Mytheme_get_avatar ', 10, 3);
7
Then we visit the website, the message operation, the avatar will naturally become more said to provide the Avatar