[buddypress-trac] [BuddyPress Trac] #5715: Profile image placeholders

buddypress-trac noreply at wordpress.org
Wed Jan 17 12:13:03 UTC 2018

#5715: Profile image placeholders
 Reporter:  sooskriszta       |       Owner:
     Type:  enhancement       |      Status:  new
 Priority:  normal            |   Milestone:  Future Release
Component:  Extended Profile  |     Version:
 Severity:  normal            |  Resolution:
 Keywords:  dev-feedback      |
Changes (by DJPaul):

 * keywords:  has-patch needs-testing dev-feedback => dev-feedback
 * milestone:  3.0 => Future Release


 It might be interesting to look at this. The avatar code has never been
 rewritten since its original implementation, and it's very tied to
 Automattic's Gravatar service.

 The 5715.diff patch is a good proof of concept (not to mention the plugins
 mentioned above). It shows how low-impact such a change could be. However,
 I think we've all learnt enough nowadays that we can do better, both
 technically and from a web page performance perspective.

 With this "letter-initial avatar" pitch, getting the first letter from a
 word doesn't work very well globally, especially with non-Latin alphabets.
 Perhaps Google has the resources to tackle this, we don't, but we can
 avoid making incorrect assumptions.

 (I am sure to be oversimplifying and this is only accurate to my very
 limited knowledge, so I apologise to everyone who's about to call me
 wrong. That's not my intent!)

 e.g. I'm reliably informed that in Chinese, names are typically three
 glyphs long. The first glyph tends to be the surname (e.g. li, wong, chan,
 lee, xe) and the second and third glyphs make up the first name (e.g.
 "jen" and "ny" for "jenny"). You can't parse glyphs into "letters", so
 it's impossible to grab a "J" from that; we'd have to show the whole
 glyph, and, e.g. that might only be half the sounds of someone's name.
 We'd butcher it!

 e.g. I'm reliably informed that in Cyrillic, and especially Bulgarian, you
 can only use the first letter if it's a vowel (or starts with one). I
 think even then, there might be exceptions based on how that letter sounds
 when pronounced.

 I think:

 * A new system needs to be designed so that people can add support for a
 custom avatar type efficiently (e.g. a specialised Chinese extension), or
 disable them entirely.
 * `bp_core_fetch_avatar()` would remain the entry point, but I can see
 that function being totally gutted. It does too many things at the moment.
 We should not add more complexity to it.
 * We'd ship with a Gravatar avatar type to start with.
 * Our own "BP profile photo" feature would integrate into this new system
 as an avatar type extension -- just like Gravatar.
 * For all avatar types, but especially Gravatar, we can enhance fallback
 support. We can fix/bring back the ability to use a local fallback image
 (e.g. on a domain that Gravatar can't access).
         * For Gravatar, we'd do this by caching if the user's email has a
 Gravatar set. If not, use the local fallback (or choose to use Gravatar's
         * Specifically with Gravatar, we'd also save a ton of HTTP
 requests if our defaults were smart.

Ticket URL: <https://buddypress.trac.wordpress.org/ticket/5715#comment:18>
BuddyPress Trac <http://buddypress.org/>
BuddyPress Trac

More information about the buddypress-trac mailing list