2017-08-08 64 views

回答

-2

可以使用width方法

$("#imageID").width() > 2 
0

您可以使用图像元素的naturalWidth和naturalHeight属性。

if(document.getElementById("imageID").naturalWidth > 2) { // TO DO: do something 
    }