Recently was annoyed by the spam comments, some of the visual is artificial commentary, but with the ads link, looking disgusting, most do not gravatar avatar, so Benbow decided to prevent the visitors do not have the Avatar normal submission of comments,Edit the functions.php file for the subject you are using, and add the following code:
The code is as follows
Copy Code
/** @author: Vfhky September 11, 2013 20:23* @param
According to the feedback from the network users, through the use of well-known social comment service providers to say that the provision of domestic Gravatar services, replace the default Gravatar function can solve the problem, and the access speed is very good.
Workaround 1: Use Gravatar HTTPS (apply to any topic)
In the topic directory, locate and open the
Gravatar Registered Address: https://en.gravatar.com/
Copy the Code code as follows:
"" ' Gravatar
`_"""
# Import code for encoding URLs and generating MD5 hashesImport Urllib2, Hashlib
# Make response slow if verify whether default avatar or not.# So to JS do it, see '/static/js/article.js '.def gravatar_url (email, size=40, verify_default=false):"" "Construct the
WordPress prohibit call official Gravatar Avatar call SSL avatar link boost loading speed, Wordpressgravatar
Add the following code to the end of the functions.php file in the theme (Appearance > Edit >functions.php)
1 // official Gravatar Avatar call SSL avatar link 2 function Get_ssl_avatar ($avatar) {3 $avatarpreg_replace ('/.*\/avatar\/(. *) \?s= ([\d]+) .*/', ',$avatar); 4 return $avatar ; 5 }
htt
Catalogue [-]Normal version Gitlab:Version Omnibus GitlabBackground: Gravatar Service has not been accessible recently, many services have been suffered, although not affected by the use but very unsightly.Recently I was trying to Omnibus Gitlab, ready to see if it can be solved, found that the combination of common online Duoshuo CDN Way is still relatively easy, recorded as follows:Normal version Gitlab:To edit Gitlab.yml, find the following section
Gravatar Avatar has a very good versatility, but has been innocent interception, for unable to load avatar URL, we in the WordPress system by modifying the default URL link can be achieved to restore the Avatar function.
Modify the file path to /wp-includes/pluggable.phpSome of the code in the replacement file is as follows:if (Is_ssl ()) { $host = ' https://secure.gravatar.com '; Else { if (! Empty($email)) $host =
Wordpress prohibits calling the official Gravatar profile picture to call the ssl profile picture link to increase the loading speed. wordpressgravatar. Wordpress prohibits calling the official Gravatar profile picture to call the ssl profile picture link to speed up loading. wordpressgravatar functions in the topic. add the following code to the end of the PHP file (the appearance editing fu wordpress proh
After the installation of WordPress, found that the site is very slow to open.The reason for this is that it's always known because Google fonts can't be loaded and Gravatar avatars can't load.In the online search, said to be the Google font loading connection modified under, and Gravatar Avatar Load connection modified under.But modify the source file, the next time the WordPress upgrade will expire.On the
Provides a variety of official and user-released code examples. For code reference, you are welcome to exchange and learn that the wordpress Avatar system has always been using the Global Avatar gravatar. I want to use this avatar system in my project. After reviewing wordpress, you can simply modify it to get the gravatar function get_avatar_src you want. This function returns the required Avatar address.
In comments using BlogEngine. NET, Email must be filled in because it uses the Gravatars Web Service input parameter. As for what is Gravatar, You can see below:
My Gravatars
What is a gravatar?
A gravatar, orGLoballyREcognizedAvatar, Is quite simply an 80x80 pixel avatar image that follows you from weblog to weblog appearing beside your name when you commen
Reprint please indicate the source: http://blog.csdn.net/dongdong9223/article/details/51161344This article comes from "I'm a fish on the hook" blog.
For a lot of websites, blog messages, I have two questions:
Blog message will leave the mail, and is required to fill;
why some messages can automatically drill out of the message of the head (obviously can be seen as a personal head), and some messages are not
Later know, the original is to use Gravatar
Improved function: Supports different sizes of avatars, and supports the automatic creation of cache directories.
Below all don't say any more, put the code into the function.php of your subject can be:
The code is as follows
Copy Code
Cache Gravatar AvatarAdd_filter (' Get_avatar ', ' Fanly_cache_avatar ');function Fanly_cache_avatar ($avatar) {if (!is_dir (' Avatar '))//Determine if there is a cache directorymkdir (' Av
Gravatar's profile picture is now a common method for calling blogs. many of my friends' personal blogs use Gravatar's profile picture, but recently many webmasters have found it slow to open Gravatar's profile picture, so how can we solve the problem of Gravatar Image playing... gravatar's profile picture is now a common method for calling blogs. many of my friends' personal blogs use Gravatar's profile picture, but recently many webmasters have foun
Background: Gravatar Service has not been accessible recently, many services have been suffered, although not affected by the use but very unsightly. Recently, I was trying to Omnibus the Gitlab, I would like to see if it can be solved, found that the combination of common online duoshuo CDN way is relatively easy, recorded as follows: Normal version Gitlab:Edit gitlab.yml , find the following section: # # Gravatargravatar: enabled:true
Gravatar registration address: https://en.gravatar.com/
Copy codeThe Code is as follows:"'Gravatar
# Import code for encoding urls and generating md5 hashesImport urllib2, hashlib
# Make response slow if verify whether default avatar or not.# So let js do it, see '/static/js/article. js '.Def gravatar_url (email, size = 40, verify_default = False ):"Construct the grava
Because of some well-known reasons, a lot of open source JS library used by foreign CDN hosting method in the domestic speed is not satisfactory. So we made this project, hosted all of Cdnjs's open source JS libraries and reversed Google Fonts, Ajax and Gravatar, all supported HTTP and HTTPS 1, cdnjs Open source JS libraryThe approach we use is to synchronize Cdnjs Github (http://t.cn/REVf3N2) on a daily schedule.All JS/CSS libraries can find the link
Create a folder in the wordpress Directory: avatar. The folder permission is 755. If you do not have the folder permission, set it to 777. This is the path to the gravatar avatar cache.Set default avatarCreate a default avatar, or copy it directly in the wordpress background settings, and name it "default.jpg", which is placed in the avatar folder. I can't open it. I will provide a picture I'm using.Add cache codeCopy the following c
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.