Javascript examples for jQuery:Image
Check image size with "display:none"
<html> <head> <meta name="viewport" content="width=device-width, initial-scale=1"> <script type="text/javascript" src="https://code.jquery.com/jquery-1.8.3.js"></script> <script type="text/javascript"> $(window).load(function(){// w w w .ja v a 2 s . c o m console.log("image width: " + $('#test').width()); }); </script> </head> <body> <img src="http://www.java2s.com/style/download.png" style="display:none;" id="test"> </body> </html>