Note that there are some explanatory texts on larger screens.

plurals
  1. POreading a file from outside webapp container in groovy
    primarykey
    data
    text
    <p>Hi I am trying to read an xml file from outside the web-app container, It works fine when the xml file is in a directory inside the web-app container but doesnt work when I try to access it from a directory location outside web-app. I am actually writing the XML file successfully before I try to read it, in any appropriate location in the disk. I tried paths like c:/xmls/my1.xml, /myprojhome/xmls/my1.xml but only /myprjhome/js/my1.xml works since js directory is inside web-ap.</p> <p>I am just trying to access by hardcoding the path in the code right now, like map.setDataURL("/myprjhome/js/my1.xml"); - this works but others dont, they give data error - not able to find file</p> <p>Its a windows system I am working on right now, do I need to set the url for the map in some other way? (for eg. using file.seperator)</p> <p><em>I am Using Fusion Maps - a flash based map chart tool which accepts data in xml format, so I import a javascript file which is FusionMaps.js , and this has all the functions like setDataURL inside it. I am doing this in the javascript to render the chart :</em> </p> <pre><code> &lt;script&gt; var map = new FusionMaps("/gra/swf/Maps/FCMap_World.swf", "Map1Id", "750", "400", "0", "0"); map.SetDataURL(URL of the dataxml); &lt;/script&gt; </code></pre> <p><em>The chart shows the map only if the URL is valid, else it shows invalid URL error, I tried to use the File protocol (File:///c:/cmls/mtxml.xml) but it doesnt work. Is it because of the Flash sandbox security model not allowing access to resources outside a domain of the swf file? since you can see that the swf file is located in some other path.. (that path is in web-app..)</em></p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload