[wp-trac] [WordPress Trac] #35920: Function to check if user has a gravatar account

WordPress Trac noreply at wordpress.org
Tue Feb 23 14:49:26 UTC 2016


#35920: Function to check if user has a gravatar account
-----------------------------+------------------------------
 Reporter:  wordpresssites   |       Owner:
     Type:  feature request  |      Status:  new
 Priority:  normal           |   Milestone:  Awaiting Review
Component:  Users            |     Version:  trunk
 Severity:  normal           |  Resolution:
 Keywords:  close            |     Focuses:
-----------------------------+------------------------------
Changes (by swissspidy):

 * keywords:   => close


Comment:

 The `get_avatar()` / `get_avatar_data()` function defaults to use
 Gravatar, though any plugin can override this. So just checking if a user
 has a Gravatar would not work. Also, since it's not actually needed in
 core there's not really an urge to implement this. Just add the suggested
 function from the codex in your plugin.

 If you want a fallback for the case a Gravatar does not exist, simply
 override the default param, e.g. by filtering the `avatar_default` option.

 For example, this will load the specified fallback URL:

 `http://www.gravatar.com/avatar/someuser?d=<fallback-url>&s=512`

--
Ticket URL: <https://core.trac.wordpress.org/ticket/35920#comment:1>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list