Single post Featured image size - custom class

Is there a way to create a css class and then some way apply to the featured image for a given post. That way when I have square images I can size them differently than when I have a rectangular featured image.

Also, is there a way to change the size of featured videos. Thanks.

Hello Ravi,

Thanks for writing in!

There is a way. Please edit the post.

Find the Post Settings and insert the custom body class;

And then use this custom css to target the featured image:

.custom-class .entry-thumb img {
  min-width: none;
  margin-left: auto;
  margin-right: auto;
}

And to make the video smaller, change the “Aspect Ratio”.

Hope this helps.

Thank you, Runel, that worked very well!

Glad that we could be of help :slight_smile:.

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.