<body>
<div class="wrap" style="min-height:400px">
<div class="i-img"></div>
<div class="main">
<h1 style="text-align:center; margin-top:50px">支付成功!</h1>
<h3 style="text-align:center; margin-top:20px">即将关闭: <span id="num">5</span>秒</h3>
</div>
</div>
</body>
<script>
$(function() {
jump(5);
});
function jump(count) {
window.setTimeout(function(){
count--;
if(count > 0) {
$('#num').text(count);
jump(count);
} else {
window.opener=null;
window.open('','_self');
window.close();
}
}, 1000);
}
</script>
js 无提示自动定时关闭页面
最新推荐文章于 2024-07-22 17:21:17 发布