📜  位置 javascript 重定向 - Javascript 代码示例

📅  最后修改于: 2022-03-11 15:01:17.929000             🧑  作者: Mango

代码示例4
// similar as an HTTP redirect, page will be not in browser history
window.location.replace("/replaced.html");

// similar as clicking on a link, page will be on history :-)
window.location.href = "/replaced.html";