Set Image width=’x%’ (percentage width not pixel width) when inserted via the media manager?

When uploading images via the media manager there are a couple of set sizes available such as thumb, medium and large.

I do know how to add additional sizes, but I have yet to get it to insert an image with width=”x%”.

the concept is that i am building an adaptive theme and I never want the inserted image to be larger than the container even upon browser resize,

By manually editing the inserted image code to include widths with a %, then it works just fine. However trying to get my users to remember this is downright impossible.

What I would like would be a button to insert an image into a post with a set % (percentage) instead of a set pixel width.

possible?

1 Answer
1

I guess what you’re looking for is the $content_width global that would basically limit the width of your images, used in functions.php. Some more info here: http://mainstreetopen.com/wordpress-26-and-full-width-images/

Leave a Comment