一些实用的jQuery代码片段

darkalliance 31 0 txt 2019-01-07 05:01:04

1.JQuery得到用户的IP: $.getJSON("http://jsonip.appspot.com?callback=?",function(data){ alert("Your ip:"+data.ip); }); 2.JQuery查看图片的宽度和高度 var theImage = new Image(); theImage.src = $('#imageid').attr("src"); alert("Width:"+theImage.width); alert("Height"+theImage.height); 3.JQu

用户评论
请输入评论内容
评分:
暂无评论