获取SCRIPT1014:来自本地js文件的IE中的字符无效 [英] Getting SCRIPT1014: Invalid character in IE from local js file

查看:3023
本文介绍了获取SCRIPT1014:来自本地js文件的IE中的字符无效的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在开发一个本地存储的网站,并且在我测试的所有浏览器中都运行良好,除了IE的任何版本。
它为每个js文件提供了SCRIPT1014:无效字符,我将其包含在脚本标记中,例如:< script src =Scripts / jquery-1.9。 1.min.js>< / script>

I'm developing a site which is stored locally, and works great in all browsers I've tested except for any versions of IE. It gives me "SCRIPT1014: Invalid character" for each js-file which I've included in script-tags like this for instance: <script src="Scripts/jquery-1.9.1.min.js"></script>

这会产生以下错误:

SCRIPT1014: Invalid character 
jquery-1.9.1.min.js, line 1 character 1

如果我然后单击错误以查看文件,即开发人员工具,它看起来像这样:

If I then click the error to view the file in ie developer tools it looks like this:

?? I?%&/m?{J?J??t??`$ؐ@??????iG#)?*??eVe]f@?흼??{???{???;?N'????\fdl??J?ɞ!????~|?"????

我除了这是一个常见的问题(或者人们不会在ie中查看本地存储的网页?)但是我在搜索时找不到多少,而且我发现没有帮助。

如何解决这个问题?

I'd except this to be a common problem (Or don't people ever view locally stored webpages in ie?) but I didn't find much when searching, and what I found didn't help.
How to get around this this?

推荐答案

有在这里是一个类似的问题: SCRIPT1014:无效字符

There is a similar problem here: SCRIPT1014: Invalid character

我会检查本地脚本的浏览器安全设置。

I would check the browser security settings for local scripts.

您可以尝试将此添加到您的页面,看看它是否有效:

You can try adding this to your page and see if it works:

<!-- saved from url=(0016)http://localhost -->

或者您可以将本地Intranet区域设置为低,如果启用则禁用保护模式。

or you can set the 'local intranet' zone to low and disable protected mode if on.

http://msdn.microsoft.com/en-us/library/ms537628(v = vs.85).aspx

编辑:在评论中回答 - 清除浏览器缓存。

Answer in comments - cleared browser cache.

这篇关于获取SCRIPT1014:来自本地js文件的IE中的字符无效的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆