$('pic2').delay(1000).show(1000)delay(时间) 延时多少秒执行
<script src="jquery-1.7.1.min.js"></script>
<script language="javascript">
window.onload=initial
function initial(){
$('#pic2').hide()
$('#pic3').hide()
$('#pic4').hide()
picShow(1,2)
}
function picShow(last,next){
lastname='#'+("pic"+last)//需要消失的图片的选择器
nextname='#'+("pic"+next)//需要显示的图片的选择器
// $(lastname).hide(1000,function(){
// last<4?$(nextname).show(1000,nextturn(next)):$('#pic1').show(1000,nextturn(next))
// })
$(lastname).hide(1000)
if(last<4)
{
$(nextname).delay(1000).show(1000)
setTimeout(function(){nextturn(next)},1000)
}
else
{
$('#pic1').delay(1000).show(1000)
setTimeout(function(){nextturn(next)},1000)
}
}
function nextturn(last){
last<4?picShow(last,last+1):picShow(last,1)
}
</script>
多谢,我在论坛搜索的时候时候看到你的帖子了。我是按你在帖子里的方法,因为userchromejs在地址栏内,于是我就用inserafter让其他基本图标,目前有adblock edge,lastpass,greasemonkey,stylish,autoproxy于是我就给写成这样了……[mw_shl_code=javascript,true]{ id: "abp-toolbarbutton", insertAfter: "userChromebtnMenu" },{ id: "lpt_lastpass-compact-btn", insertAfter: "abp-toolbarbutton" },{ id: "greasemonkey-tbb", insertAfter: "lpt_lastpass-compact-btn" },{ id: "stylish-toolbar-button", insertAfter: "greasemonkey-tbb" },{ id: "aup-toolbarbutton", insertAfter: "stylish-toolbar-button" },[/mw_shl_code] 查看原帖>>