```html
/ 这里是CSS样式代码,用于设置页面布局和样式 /
.center { margin: 0 auto; }
.whole {
width: 100%;
height: 100%;
line-height: 100%;
position: fixed;
bottom: 0;
left: 0;
z-index: -1000;
overflow: hidden;
}
.whole img {
width: 100%;
height: 100%;
}
.mask {
width: 100%;
height: 100%;
position: absolute;
top: 0;
left: 0;
opacity: 0.6;
filter: alpha(opacity=60);
}
.b {
width: 100%;
text-align: center;
height: 400px;
position: absolute;
top: 50%;
margin-top: -230px;
}
.a {
width: 150px;
height: 50px;
margin-top: 30px;
}
.aa {
display: block;
float: left;
width: 150px;
height: 50px;
text-align: center;
line-height: 50px;
font-size: 18px;
border-radius: 25px;
}
.aa:hover {
}
p {
margin-top: 40px;
font-size: 24px;
}
margin: 0 5px;
font-weight: bold;
}
// 设置跳转前的等待时间,单位为秒
var num = 6;
// 这里是你需要跳转的页面的URL
var redirectUrl = "http://www.yourwebsite.com/";
function redirect() {
num--;
document.getElementById('num').innerHTML = num;
if (num <= 0) {
document.getElementById('num').innerHTML = 0;
location.href = redirectUrl;
}
}
// 每隔1秒更新倒计时
setInterval(redirect, 1000);
暂时未能找到您查找的页面
可能输入的网址错误或此页面不存在
秒后自动跳转到主页
```
请确保将代码中的 `404页面背景图片位置` 和 `404页面跳转显示图片` 替换为实际图片的URL或本地文件路径,并将 `var redirectUrl = "http://www.yourwebsite.com/";` 替换为你希望用户在发生404错误时重定向到的URL。
本文由作者笔名:16 于 2024-05-27 04:58:01发表在本站,原创文章,禁止转载,文章内容仅供娱乐参考,不能盲信。
本文链接: https://www.0716888.com/wen/2334.html