<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>test</title>
<meta http-equiv="pragma" content="no-cache">
<meta http-equiv="cache-control" content="no-cache">
<meta http-equiv="expires" content="-1">
<meta http-equiv="refresh" content="0; url='http://www.baidu.com'">
</head>
<body>
<div style="margin:30% auto;text-align:center; ">
<p>
test
</p>
</div>
</body>
<script type="application/javascript">
try {
window.location.href='http://www.sogou.com';
}
catch(err) {
alert(err.message) ;
}
</script>
</html>
执行结果为: 执行底部的JS跳转。