Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

how to set image width and height dynamically in javascript

document.addEventListener('DOMContentLoaded', function() {
  var image = document.getElementById("container");
  alert(`${image.width} x ${image.height}`);
}, false);
Source by www.techiedelight.com #
 
PREVIOUS NEXT
Tagged: #set #image #width #height #dynamically #javascript
ADD COMMENT
Topic
Name
5+4 =