js 路径跳转

那要看当前页面与所要跳转页面的位置关系

同在一个目录的 document.location = './b.html'

一级目录的 document.location = '../b.html'

跳到不同域的 document.location = 'http://www.baidu.com/'

原文地址:https://www.cnblogs.com/zhuxiaodong/p/6640724.html