I have a function that creates a bio-line at the top of every post. One part gets the avatar of that user, that he uploaded in WordPress (I use a plugin so people don't need to use Gravatar for this).
function mm_author_byline()
{
if (is_single() AND (get_post_type() == 'post' OR get_post_type() == 'theme_product_review')) {
?>
<div class="mm-byline-image">
<?= get_avatar(get_the_author_meta('ID')) ?>
</div>
<?php
}
}
The problem now is, that this image is neither cropped, nor is it sized down. It takes the original image, that can be huge. How can I get a sized down version of the avatar image?