Archive for the ‘width’ Category

Measuring Image Widths in JavaScript (Carefully!)

Posted on: No Comments
Let's say you want to find an <img> on the page and find out how wide it is in JavaScript. Maybe you need to make some choices based on that width (or height, or both) You can definitely do that. The DOM will even give you a variety of dimensions...