Reading files from hard drive with javascript

后端 未结 3 1206
南方客
南方客 2021-01-23 20:05

My application creates .xml files and stores them on the user\'s hard drive; there is a default folder that I set in the web.xml to store the files, le

3条回答
  •  天涯浪人
    2021-01-23 20:12

    It's best to expose your files via HTTP and use mxUtils.load("http://yoursite/static/yourfile.xml").

    Search for static files on Apache HTTP Server HowTo. Setup Apache to serve your xml files, make sure that you can view xml file in browser and then use the same url in mxUtils.load call.

提交回复
热议问题