BuddyBoss Home – Web › Support Forums › Themes › BuddyBoss theme › Change Featured Image Thumbnail Size
Tagged: featured image, thumbnail
- This topic has 6 replies, 2 contibutors, and was last updated 10 years ago by Shannon.
Question
October 19, 2014 at 5:44 pm #32724@flick-chicksI have my posts set up to be displayed on a static page and when the post’s featured image is with it the thumbnail size is a square (I think 150×150). Is this a theme setting? I have gone into Settings > Media and tried to change the thumbnail size there and it is not working, and I tried changing it on the image itself.
Is there some code that I need to put in? If it’s PHP code I will need to be walked through it carefully. I am using the child theme.
Answers
October 20, 2014 at 9:00 pm #32748@alyssa-buddyboss
AlyssaParticipant@flick-chicks this code is on line 50 of content.php
You will need to download and install the child theme. Then copy the file content.php from the parent theme into the child theme.
Find Line 50:
<?php the_post_thumbnail('thumbnail'); ?>
Change it to this:
<?php the_post_thumbnail('medium'); ?>
if that isn’t large enough try this:
<?php the_post_thumbnail('large'); ?>
October 21, 2014 at 3:06 pm #32774@flick-chicksThanks for the reply. I have tried both medium and large and neither changed the size. They were still a square and they just distorted the image within the square. All of the images are going to be the same size, I think 150w x 200h. Is it possible to set an exact size?
October 21, 2014 at 8:09 pm #32793@alyssa-buddyboss
AlyssaParticipant@flick-chicks unfortunately with the way wordpress uploads images you cannot set a custom size without image distortion.
Sorry you will also need to add this to your custom.css file:
.entry-post-thumbnail img { max-height: initial; max-width: initial; padding-right: 20px;
October 22, 2014 at 2:29 pm #32812@flick-chicksOk, so I put in the CSS and the PHP (set to large) and there were no changes. I think I’m doing everything correctly.
Any thoughts?
If you’d like to see my page I can send it to you privately. It’s not ready for public consumption yet. =)
October 22, 2014 at 4:53 pm #32817@alyssa-buddyboss
AlyssaParticipant@flick-chicks yes, that should work dandy.
October 22, 2014 at 7:16 pm #32822@flick-chicksSuper, can you please send me an email (I assume you have that data somewhere) and I’ll send you the page. I don’t want to post my email or webpage addresses here.
Thanks
- The question ‘Change Featured Image Thumbnail Size’ is closed to new replies.