且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

无法加载资源:服务器响应状态为404(找不到)ripple.js

更新时间:2022-06-16 23:14:41

可能是答案的一部分:
对于第二个错误(未找到404),对我有用的是将 config.xml 复制到根路径

May be part of the answer: For the second error (not found 404), what worked for me is to copy config.xml to the root path (where your source code is).

对于第一个错误(同步 XMLHttpRequest ,这对于模拟不重要)过程,但您可能想要查看清除控制台日志)只需编辑ripple.js

For the first error (synchronous XMLHttpRequest, which is not important for the emulating process, but you may want to see a "clear" console log) just edit ripple.js

[MAIN_DRIVE]:\Users\[YOUR_USER]\AppData\Roaming\npm\node_modules\ripple-emulator\pkg\hosted

在仿真器提示的行中,查找xhr请求。
更改

In the line that the emulator complains about, look for the xhr request. Change

xmlHttp.open("GET", utils.appLocation() + fileName, false);

xmlHttp.open("GET", utils.appLocation() + fileName, true);

完成后,希望这有帮助。
这些错误与方法无关。

and you are done, Hope this helps. These errors are not related by the way.