我写一了段代码,实现在单击”下一张“时,用过渡滤镜显示下一张照片。
在IE中完全正常,但在FF下,没有反应,无出错提示。请各位高手指点。
代码如下:
==============================================
var i=1,maxphoto=6;
function nextClick(){
i++;
if ( i>maxphoto) {i=1;};
showPhoto();
}function showPhoto(){
document.getElementById("newPhoto").filters(0).Transition=23;
document.getElementById("newPhoto").filters(0).apply();
document.getElementById("newPhoto").src="big_photo/New_"+i+".jpg";
document.getElementById("newPhoto").filters(0).play();
}newPhoto为IMG的id.
===================================================
在IE中完全正常,但在FF下,没有反应,无出错提示。请各位高手指点。
代码如下:
==============================================
var i=1,maxphoto=6;
function nextClick(){
i++;
if ( i>maxphoto) {i=1;};
showPhoto();
}function showPhoto(){
document.getElementById("newPhoto").filters(0).Transition=23;
document.getElementById("newPhoto").filters(0).apply();
document.getElementById("newPhoto").src="big_photo/New_"+i+".jpg";
document.getElementById("newPhoto").filters(0).play();
}newPhoto为IMG的id.
===================================================
解决方案 »
免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货