Learn how to modify by code the size of the user image in the comments of any Genesis Framework child theme.
By default, Genesis child themes display the Gravatar image in the comments.
And the dimensions of the image depend on the child theme you use. In the case of Genesis Sample, for example, it is 48×48 pixels.
Would you prefer to customize the size of this image to your liking?
Genesis has a filter to make it easy for you.
Snippet to resize user photo in comments
Add the following code fragment at the end of the functions.php file:
In this case, the dimensions of the image will be 96×96 pixels, to give more prominence to the user’s photograph, but you can adapt these measures to your needs.
However, if you use a much larger or smaller size than the original, it is likely that you will need to make adjustments to the CSS level so that it is displayed correctly. Keep this in mind.
You can also check out the rest of the tutorials in the Genesis Framework comment area for more information. For example, do you want to change the title of the comments? You got it. 😉
As you can see, by adding a few simple lines of code you can resize the user image used in the comments in any Genesis child theme.
Any questions? Let me know in the comments.
And if you want to give me any suggestion for future tutorials, leave it in the contact form. Advantages of being a subscriber. 😉