Facebook Likers

November 27, 2011

(Tutorial) How To Auto-Resize Photos In Blog Posts

To make all photos within your posts automatically resized to a given number of pixels, this simple code available for all bloggers to use. Smaller size photos will not be affected.

Option 1. 
Paste below code into Design>CSS>Template Designer>Advanced>Add CSS.

img {
max-width: 480px;
width: expression(this.width > 480 ? 480: true);
border: none;
text-align: center;
}
If your template post column width is 500px, change the width size accordingly.

Option 2.
Paste the code above this code.
]]></b:skin>
That's all, enjoy!

No comments:

Post a Comment

Ada nak komen apa-apa? Jemput bersila untuk menaip :p