问题
Does anyone have any idea, what can cause Ripple Emulator (newesest version) onboard newest version of Chrome to always report malformed or missing config file ("config.xml file could not be found in application's root or is malformed XML")?
I have my config.xml
present exactly at application root (i.e. in the same folder, where index.html
file, used to fire my mobile application). I don't think it's malformed since PhoneGap Bulid
builds perfectly working applications (though tested only on Android) and does not reports any problems neither with configuration file nor with compilation process.
I'm getting this error not only on my own configuration files, but also on any PhoneGap application, that I've been working with -- including: PhoneGap Hello World example application, alluny's PhoneGap Start Application, Sencha Touch Kitchen Sink demo and others. Actually I haven't found any application in my local resources, that would not cause Ripple Emulator to report problems with config.xml
file.
Of course, I set proper Chrome's settings, as instructed on Ripple Emulator page and I'm opening my Chrome with proper flag to allow it access local files via file:/// protocol.
回答1:
I am using the current Ripple UI (v0.9.15) and experienced this issue too.
For me the issue was caused by not having the config file in the right location. After I put it in the correct location, Ripple did not recognize it until I disabled/re-enabled Ripple.
What worked for me was:
- Make sure config.xml is in the www root with index.html (where you currently have it)
- Click on the green Ripple icon in the top left and disable Ripple for that page
- Re-enable Ripple
回答2:
Just solved this problem, here's what I had to do:
- Transfer the config.xml to my root path (same path as the index.html file)
- Transfer the /res folder as well or edit all the .XML entries to point to the right paths.
- Disable Ripple and then Re-Enable.
回答3:
It took me awhile to get the switch working, but opening Chrome with the --allow-file-access-from-files switch is the solution.
来源:https://stackoverflow.com/questions/14832776/phonegap-ripple-emulator-always-reports-malformed-config-xml