<script> <br>function getWH(t){ <br>console.log("width=" t.naturalWidth); <br>console.log("height=" t.naturalHeight); <br>t.width = t.naturalWidth * 2; <br>t.height = t.naturalHeight * 2; <br>} <br></script>
naturalWidth and naturalHeight are only read-only properties and cannot be used to set the size of the image and cannot be continuously enlarged.