郁闷了一段时间 原来在这里
因为Eclipse的Editor的编码问题。解决方法:
window->preferences 然后是General->Content Types,选择JavaScript Content,在下面的Default encoding,改为GBK。
重新打开.js文件,OK