How To Set Maximum Size for Images In WordPress Blog?

Posted by


Sometimes wordpress show up an image on blog which is to large and causing problems for WordPress theme. This is a common for WordPress blogs that have multiple authors where some authors or guest posters may not know how big they can make the images.

Fixing this is incredibly easy with CSS code! We need to add this code in stylesheet and setting a maximum width for images:

.postarea img
max-width: 450px;
height: auto;

In the above code we will want to replace postarea with whatever div ID or CLASS in the theme uses for the content. You can also adjust the 450px to the maximum width which would you like for images in your blog.


Shane G.

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.