The get_avatar()
function has many arguments, the last one is the interesting one, because you can pass additional classes, also described in the codex. So instead of
get_avatar( $comment, $args['avatar_size'] );
you could use
get_avatar( $comment, $args['avatar_size'], '', '', array('class' => 'myclass') );
Related Posts:
- Customize comment list markup
- child comments not displaying as nested
- Menu items description? Custom Walker for wp_nav_menu()
- Add Caret to Menu Items with Sub-Menus in WordPress Theme
- Strict Standards Error bootstrap navwalker
- Nested comments ignored for max per page in wordpress
- Any walker causes blank menu?
- Custom Comments – Parent / Nested Reply
- Why is styling comments so complex?
- Comment form not display properly?
- How to Auto Approve Comments on a Specific Page?
- comment_form() generates the wrong action url
- Extend walker – navigation, adding data attribute to a tag
- how to pull wordpress post comments to a external page
- Separated Comment from Post
- Remove “a href” from wp_list_comments()
- how to change WordPress menu markup/classes
- How to call wp_list_comments() with callback outside the loop
- Custom Nav Walker to show siblings and children of current branch?
- Create self-populating menu and add extra divs to the menu layout
- How to get comment meta values by post ID
- Compact pingback list with favicons
- How to change i18n/l10n of #reply-title? (Old title: Comment reply link not working)
- How to remove comment link title attribute?
- Comment entry screen shows even though “Allow Comments” is unchecked
- Create wordpress header with custom logo in between the menu splitting the menu into two equal parts [closed]
- WordPress empty Nav Menu error
- Jetpack Comments with fall-back
- WP_Comment_Query – Get comments and answers separately
- In this snippet how do I force the function to use gravatar rated G and fill in the alt for get_avatar()?
- Issue on Adding A Class to Bootstrap Navbar Walker Dropdown
- Custom Navigation build using wp_nav_menu and walker
- Trackbacks not displaying
- Nested comments in WordPress theme
- Change the “Default Avatar” admin option via functions.php
- Comment status shows ‘closed’ in db, but it shows ‘open’ when i echo it
- Difference between “comment_form_default_fields” AND “comment_form_fields”
- How to enable Disqus comments in a WordPress theme I’m creating from scratch? [closed]
- Same comments on all posts
- WordPress Comment spam issue
- WordPress comments title
- WordPress custom menu can’t show 3. level submenu
- Ajax Comment Upvotes – Votes don’t always register
- WordPress menu walker – Get parent item text inside end_lvl function
- Modify comments_popup_link output
- Woocommerce Theme Reviews / Comments
- How can I fix the even/odd child classes comments so that the comments are unaffected by the top-level even/odd?
- wp_update_comment not working
- Horizontal Navigation
- Strict Standards Error bootstrap navwalker
- Recent posts with comment count in “Sidebar” template [closed]
- Is there a Function so that the author of the comment can delete his own comment?
- Local theme changes upload on server but theme changes not showing
- overlay post title over post’s featured image
- WooCommerce – edit templates
- Media & Plugin screens stall
- I updated my own theme’s code and css
- How to include all files within a folder & its sub folders to functions.php?
- Group several custom global page templates in sub-folder
- Editing Them with Child Theme Basics [closed]
- Get property of non-object on theme activation
- How do I build a WordPress Profile/Author Header?
- Theme option page doesn’t save options
- change wordpress website logo url [duplicate]
- Problem with Displaying Custom Theme Page’s Content
- How to know and change the machine name of a menu?
- Need help with adding custom wordpress menu and sub-menu
- What is the general function to add a Widget area (not of a particular type)?
- Custom page template not showing on page creation
- get currently showed author ID in theme functions.php
- WordPress Post Order
- WordPress Custom font not found
- Code showing in wordpress post titles around website
- WordPress uploads do not show up and I see the white screen of death in some cases
- Why content is not adding for each blog post
- How do I control the header space in non-front pages in Twenty Seventeen?
- register_theme_directory() sees custom themes directory, but blank frontend
- Customizer Image-Picker Preview Not Working
- How to customize the colors within a stylesheet using a WordPress setting
- How can i create my Onepage smoothscrool WordPress theme?
- Target second from last post in loop
- Correct was to customise theme using get_theme_mod in scripts
- What is the best practice workflow for new website overhaul and keeping current SEO ranking? [closed]
- Two instances of the theme folder in the URL
- WordPress Twenty-Fourteen: How to Remove Home Page Header Image from Other Pages
- I want to change the author name
- Does any JavaScript file load automatically for index.php file?
- Custom theme vs theme customization?
- How to hook into wordpress upgrade procedure for a custom theme
- Child theme in separate WordPress Install
- Second page of archive is empty
- Display problems in admin dashboard when creating a new theme from scratch
- How to achieve this navigation style in wordpress navigation
- Change header image on a particular page
- Alter theme pages on language switch
- style.css not being rendered in browser
- How to hide blog by id wordpress multisite listing
- How to dowload and edit content of a website
- wp_kses allow checkbox class and checked
- Uncaught Reference error in Retina.js