Open aslakr opened 4 years ago
I suppose bp_gravatar_url
is similar only for BuddyPress, but get_avatar_url()
(and get_avatar_data()
) was introduced later in WordPress 4.2 (in 2015)?
There are new (pre_)get_avatar_data filters which look perfect for new injection
The same applies when using @pfefferle pfefferle/wordpress-activitypub, i.e. Mastadon will use gravatar instead of federated libravatar.
Do you have any suggestion on how the code should be changed to use the (pre_)get_avatar_data
filters?
pre_get_avatar_data
is what we are using for Webmentions:
Anyone care to take over the plugin?
Since som plugins use
get_avatar_url()
to get the url of the avtar, would it be possible to override that?Example of plugins using
get_avatar_url()
:https://github.com/willnorris/wordpress-opengraph/blob/eaefc0fabddb9f729a6179c1c8e5f7b99788b43c/opengraph.php#L205-L208
https://github.com/pfefferle/wordpress-webfinger/blob/07bf15c5eac5602478e1c4fb1f2f47ff851b1b7d/includes/class-webfinger.php#L117-L118
https://github.com/manton/jsonfeed-wp/blob/68d8e8ccbd3f8fed31a5eb954924031077cceec6/feed-json-functions.php#L142-L156
https://github.com/Automattic/Co-Authors-Plus/blob/703d0404ff27db25066f322ae9e79e440cdc2b34/co-authors-plus.php#L137-L138