[英]js files are loading in unreadable format
I was working on a Web App. 我正在开发Web应用程序。 I used a "✗" UTF-8 character as a delete button.
我使用“✗” UTF-8字符作为删除按钮。 Eclipse asked me to save file in UTF-8 format i told yes.
Eclipse要求我以UTF-8格式保存文件,我告诉是。 Everything worked fine.
一切正常。 But next day when i ran the app again it is throwing exception
"Uncaught SyntaxError: Unexpected token ILLEGAL"
. 但是第二天,当我再次运行该应用程序时,它将引发异常
"Uncaught SyntaxError: Unexpected token ILLEGAL"
。 When i checked it, all javascript file is loading in unreadable format. 当我检查它时,所有的javascript文件都以不可读的格式加载。 See image below.
参见下图。
I tried to replace that character with its UNICODE "✗" 我试图用UNICODE“✗”替换该字符。 and saved all js files in default encoding, but didn't help.
并以默认编码保存了所有js文件,但没有帮助。
Do anyone know why is this happening? 有人知道为什么会这样吗?
It sounds like you saved in a different text format than you loaded it and/or loaded it in a different text format that you saved it. 听起来您保存的文本格式与加载和/或保存的文本格式不同。 Without recommending a tool, I would see if you can use something to change the code-page/text-format and then try stuff.
在不推荐工具的情况下,我将查看您是否可以使用某些方法来更改代码页/文本格式,然后尝试使用。
However, seeing as what you are showing on teh screen is 3rd part stuff, you could just more easily re-download it where you got it the first time, or perhaps unpack it if you saved the installer/zip-file. 但是,由于屏幕上显示的内容是第3部分,您可以更轻松地在第一次下载的地方重新下载它,或者如果保存了安装程序/ zip文件,则可以解压缩它。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.