get css dimensions code example
Example 1: python get image dimensions
from PIL import Image
im = Image.open('whatever.png')
width, height = im.size
Example 2: javascript get image dimensions
var img = document.getElementById("myImageID");
var imgWidth = img.clientWidth;
var imgHeight = img.clientHeight;