Follow

Keep Up to Date with the Most Important News

By pressing the Subscribe button, you confirm that you have read and are agreeing to our Privacy Policy and Terms of Use
Contact

My image size is fixed. How to make it flexible?

I have this custom coded blog page created – Link

The width of the blog page content is perfect and this is how I want it to be. But If you look at the images, they are also stretched to match the width of the content. I don’t want that to happen and moreover, the images are stretched

Here is the css code that I’ve added to create the content’s width:

MEDevel.com: Open-source for Healthcare and Education

Collecting and validating open-source software for healthcare, education, enterprise, development, medical imaging, medical records, and digital pathology.

Visit Medevel

.post.type-post.status-publish * {width: 800px !important;max-width: 800px !important; margin: auto !important;}
How to make the images stay flexible and change size to my needs while keeping the content’s width same?

Please help me out here.

Thanks!

>Solution :

This works for me:

.post.type-post.status-publish img {
    width:auto !important;
}
Add a comment

Leave a Reply

Keep Up to Date with the Most Important News

By pressing the Subscribe button, you confirm that you have read and are agreeing to our Privacy Policy and Terms of Use

Discover more from Dev solutions

Subscribe now to keep reading and get access to the full archive.

Continue reading