Title: inline css
Last modified: May 22, 2020

---

# inline css

 *  Resolved [Jon Scaife](https://wordpress.org/support/users/jonscaife/)
 * (@jonscaife)
 * [6 years ago](https://wordpress.org/support/topic/inline-css-14/)
 * Hi
    I have recently enabled a content security policy which has flagged up inline
   css which I would prefer to remove where I can. I notice that if I use avatars
   then there is a bit of inline CSS included with each that specifies a padding-
   left and min-height. I would rather control this through my child theme stylesheet
   and turn off the inline CSS. Is there a way to do this, or could one be added?
   Either by applying a filter function, or (even better) an option in the shortcode
 * The line that applies this is in Util.php line 104
 * Thanks

Viewing 3 replies - 1 through 3 (of 3 total)

 *  [Andy Keith](https://wordpress.org/support/users/andykeith/)
 * (@andykeith)
 * [6 years ago](https://wordpress.org/support/topic/inline-css-14/#post-12894499)
 * Hi,
 * Thanks for getting in touch. We’ve just released a new version of the plugin (
   1.1.2) which includes a filter to enable/disable the inline CSS for avatars. 
   You’ll have to add some PHP code to your child theme (or other plugin) to disable
   it. This is the code you would need to use:
 *     ```
       add_filter( 'better_recent_comments_enable_avatar_inline_css', '__return_false' );
       ```
   
 * That will disable the CSS on the comment-wrap element and you can add your own
   styles via your theme’s stylesheet.
 * Hope that helps…
 *  Thread Starter [Jon Scaife](https://wordpress.org/support/users/jonscaife/)
 * (@jonscaife)
 * [6 years ago](https://wordpress.org/support/topic/inline-css-14/#post-12901224)
 * Hi Andy
    Thank you for the superb and speedy update. The tweak you provided works
   spot on with the latest version. I’ve added my own css to my child theme stylesheet
   and so no longer have any inline CSS which is fantastic (both for SEO and for
   Content Security Policy). Thanks again!
 *  [Andy Keith](https://wordpress.org/support/users/andykeith/)
 * (@andykeith)
 * [6 years ago](https://wordpress.org/support/topic/inline-css-14/#post-12901663)
 * Great, glad it’s all sorted 🙂

Viewing 3 replies - 1 through 3 (of 3 total)

The topic ‘inline css’ is closed to new replies.

 * ![](https://ps.w.org/better-recent-comments/assets/icon.svg?rev=3100094)
 * [Better Recent Comments](https://wordpress.org/plugins/better-recent-comments/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/better-recent-comments/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/better-recent-comments/)
 * [Active Topics](https://wordpress.org/support/plugin/better-recent-comments/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/better-recent-comments/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/better-recent-comments/reviews/)

## Tags

 * [css](https://wordpress.org/support/topic-tag/css/)
 * [filter](https://wordpress.org/support/topic-tag/filter/)
 * [function](https://wordpress.org/support/topic-tag/function/)
 * [shortcode](https://wordpress.org/support/topic-tag/shortcode/)

 * 3 replies
 * 2 participants
 * Last reply from: [Andy Keith](https://wordpress.org/support/users/andykeith/)
 * Last activity: [6 years ago](https://wordpress.org/support/topic/inline-css-14/#post-12901663)
 * Status: resolved