Answers for "javascript get width of image"

1

javascript get image width and height

var img = new Image();
img.onload = function() {
  alert(this.width + 'x' + this.height);
}
img.src = 'http://www.google.com/intl/en_ALL/images/logo.gif';
Posted by: Guest on March-04-2020
1

javascript get image dimensions

var img = document.getElementById("myImageID"); 
var imgWidth = img.clientWidth;
var imgHeight = img.clientHeight;
Posted by: Guest on July-31-2019
0

javascript get width of image

image.width
Posted by: Guest on July-01-2020

Code answers related to "javascript get width of image"

Code answers related to "Javascript"

Browse Popular Code Answers by Language