[wp-trac] [WordPress Trac] #16976: Don't use photo as avatar class in comments
WordPress Trac
wp-trac at lists.automattic.com
Sun Mar 27 01:07:30 UTC 2011
#16976: Don't use photo as avatar class in comments
--------------------------+------------------------------
Reporter: Okoth1 | Owner:
Type: defect (bug) | Status: new
Priority: normal | Milestone: Awaiting Review
Component: Comments | Version: 3.1
Severity: normal | Resolution:
Keywords: 2nd-opinion |
--------------------------+------------------------------
Changes (by dd32):
* keywords: => 2nd-opinion
Comment:
Just removing the class has the problem that people currently styling that
class will lose out.
Also, These are hCard classes, see #8264 for where it was implemented.
You could do something such as this if you care enough:
{{{
add_filter('get_avatar', 'remove_photo_class');
function remove_photo_class($avatar) {
return str_replace(' photo', ' comment-photo', $avatar);
}
}}}
(That is a wide-ranging replace there, but it's the most simplistic based
on the fact ' photo' shouldn't be anywhere else in that string if you're
using the default Gravatar avatar system)
--
Ticket URL: <http://core.trac.wordpress.org/ticket/16976#comment:1>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software
More information about the wp-trac
mailing list