2014-03-29

get image dimensions in JavaScript

var img = new Image();
img.src = "pathToFile";
width = img.width;
height = img.height;