0

I tried to set size and class for wordpress avatar in comments but I couldnt.

<?php if ($args['avatar_size'] != 0) echo get_avatar( $comment, array('class'         => 'media-object') ); ?>

I want to set avatar in comments to 70x70 size and "media-object thumbnail" class then show it.

What is my mistake?

I re-wrote comment function in html5blank for better css but as a last thing, I couldnt do this.

php arrays wordpress

1 Answer 1

0

Try this

<?php if ($args['avatar_size'] != 0) echo get_avatar($comment,'70',$default, $alt,array('class'=>array('media-object','thumbnail'))); ?>

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.