<script type="text/javascript" src="http://res.wx.qq.com/open/js/jweixin-1.0.0.js"></script>
<script>
// 点击查看大图
function funcReadImgInfo(){
var imgs = [];
var imgObj = $("img");//这里改成相应的对象
for(var i=0; i<imgObj.length; i++){
imgs.push(imgObj.eq(i).attr('src'));
imgObj.eq(i).click(function(){
var nowImgurl = $(this).attr('src');
WeixinJSBridge.invoke("imagePreview",{
"urls":imgs,
"current":nowImgurl
});
});
}
}
funcReadImgInfo();
</script>
网友评论