Auto resizing images to fit max width?

  • Author
  • #536056

    Hello all, hope you can help me. I know this code can squash an image in the post to fit the maximum width of my column:

    p img {
    max-width: 100%;

    However, I would prefer the image was automatically resized to fit the maximum width. Anyone have the code for this?

    I’m sorry, but I’m not very good with code!


    We need a link to the blog that you are talking about.

    There is one way I can think of doing this, but it can be messy and really mess things up if not done exactly right, but it depends on whether the blog is hosted here or not.


    Sorry, it’s (not hosted here)

    I had it “kind of” fixed by changing the maximum medium / large width for media settings, but that’s bugging out on me now. I’d much prefer to fix it with code for the stylesheet.


    It’s going to be best if you ask over at http://wordpress.ORG/support/ as that is where self-hosted wordpress blogs are supported. I’m sure one of the people over there will have a much better way of doing it than the messy workaround we would have to use here.

The topic ‘Auto resizing images to fit max width?’ is closed to new replies.