CSS: Resizing Large Images to Fit in Containers
I was playing around with the MX4 theme by Mike. And I noticed how the images I post are resized to fit within the container.
For example, my last post with the snapshot has a 450px image in it. When I changed to the MX4 theme, my image was resize (with CSS!) to by 342px.
So I was looking through the stylesheet and found this nice code:
p img { max-width: 100%; }
This CSS code will resize the image to fit the container if there is any overflow. That’ll come in very handy. ;)
I’m in love with this MX4 WordPress 1.5 theme. If you like it to, download it here.
Related Products:
Understanding Basic Electronics (Softcover)Understanding Basic Electronics
Kindle Fire HD 7", Dolby Audio, Dual-Band Wi-Fi, 16 GB - Includes Special OffersWorld's most advanced 7" tablet with stunning HD display, exclusive Dolby audio, and the fastest Wi-Fi found on a tablet. When it comes to HD displays... Read More >
Make: Electronics (Learning by Discovery)"This is teaching at its best!"
--Hans Camenzind, inventor of the 555 timer (the world's most successful integrated circuit), and author of... Read More >


@






