Warning: file_get_contents(/data/phpspider/zhask/data//catemap/3/html/83.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Javascript 为什么我的window.navigate代码失败?_Javascript_Html - Fatal编程技术网

Javascript 为什么我的window.navigate代码失败?

Javascript 为什么我的window.navigate代码失败?,javascript,html,Javascript,Html,我有一个 当我尝试做window.navigatethisitem;JS在这一行失败了…为什么?DOM中没有在窗口中导航的方法。DOM中没有在窗口中导航的方法。我想你的意思是:window.location='thisitem' 我想你的意思是:window.location='thisitem' 因为window.navigate是IE特有的,不兼容跨浏览器。使用window.location.href='thisitem'。因为window.navigate是IE特有的,不兼容跨浏览器。使用

我有一个


当我尝试做window.navigatethisitem;JS在这一行失败了…为什么?

DOM中没有在窗口中导航的方法。

DOM中没有在窗口中导航的方法。

我想你的意思是:window.location='thisitem'

我想你的意思是:window.location='thisitem'

因为window.navigate是IE特有的,不兼容跨浏览器。使用window.location.href='thisitem'。

因为window.navigate是IE特有的,不兼容跨浏览器。使用window.location.href='thisitem'。

您可以使用window.location.hash方法执行此操作您可以使用window.location.hash方法执行此操作我正在使用phonegap…尝试导航到单个HTML文件的某个部分。它是同一文档中某个片段的相对URL。非常合理。我正在使用phonegap…尝试导航到单个HTML文件的某个部分。它是同一文档中某个片段的相对URL。这很有道理。