// 模拟 HTTP 301 Redirect 的跳转。跳转后浏览器不会显示后退按钮。 window.location.replace("http://www.example.com"); // 模拟用户点击链接后的跳转,用户可以点击后退按钮。 window.location.href = "http://www.example.com";