Saturday, February 16, 2002

Why I don't use WIDTH nor WEIGHT in the HTML <IMG> tag:

Using these 2 attributes has a positive impact on the way some sites load (specially if there are many images near one another, for example when you make a sort of image map/menu from several smaller images that fit next to each other). Still without them it's possible to edit an image (changing it's width and/or height attributes) on a site without having to change the HTML code of the pages where you use it, this could be especially disturbing if the images is used in many different pages (might be hard to keep track of all of them), eventually on other servers (if image hot-linking is not prevented at your server), to which you might even not have update access.

No comments: