How to force comment author avatars to one size in Divi

Oct 30, 2019

Disclaimer: This site is a labour of love, but love doesn’t buy me matcha lattes. Affiliate commissions for awesome internet tools, on the other hand, totally buys me matcha lattes. This post probably contains some affiliate links. Read my affiliate disclaimer here.

So I found a problem in Divi tonight.

Weird Gravatar Size

To be fair, this isn’t exclusively a Divi problem. This is a Gravatar problem. Occasionally, Gravatar images show up at a weirdly large size, while others show up normally.

It would be one thing if all Gravatars showed up large, but this mix doesn’t work because, as you can see, it covers up comment text, and it hides behind the avatar for the following comment.

But, I wrote just a couple lines of code, and now all Gravatars match.

Viola!

Step 1: Take this code.

.comment_avatar {
height: 62px;
width: 62px;
}

Embed it in the CSS in Divi Theme Options.

That’s it!

If this helps you, I’d love to hear about it. Drop me a comment below.

0 Comments

Leave a Reply