最新回答 / 慕少9748393
在js中.width的寫法不正確,不能得到指定對象的寬度值,可以用.css('width')來代替,但是.css('width')輸出的值有單位,而.width()沒有單位。如window,docunment等非普通元素的值只能靠.width()才能獲得正確的寬度值,而.css('width')則不能。例如:$(window).width()輸出的是當前window窗口寬度,而$(window).css('width')則輸出的是undefined。
2016-09-17
最新回答 / 戴國俊
//查看大圖的交互操作 $('#large_container').tap(function(){ $(this).hide(); }).swipeLeft(function(){ cid++; if(cid>total){ cid=total; } else{ loadImg(cid,function(){ domImage.addEventListener('webkitAnimationEnd',function(){ wImage.removeClass('a...
2016-07-14