Re: [Dev] [Jaggery] How to read files while locates outside of jaggery app?

2016-06-12 Thread Thilini Cooray
Thanks, Tanya. "file:///" worked for me. On Mon, Jun 13, 2016 at 9:54 AM, Tanya Madurapperuma wrote: > Hi Thilini, > > Try appending file:/// to your file path. I tried the below code and it > works fine for me. > Note : I'm trying to read test.txt file which resides in my CARBON_HOME > director

Re: [Dev] [Jaggery] How to read files while locates outside of jaggery app?

2016-06-12 Thread Tanya Madurapperuma
Hi Thilini, Try appending file:/// to your file path. I tried the below code and it works fine for me. Note : I'm trying to read test.txt file which resides in my CARBON_HOME directory. <% var file = new File ('file:///data/packs/ds/wso2ds-2.1.0-SNAPSHOT/test.txt'); file.open("r"); var message =

[Dev] [Jaggery] How to read files while locates outside of jaggery app?

2016-06-12 Thread Thilini Cooray
Hi all, I want to read a file from API Manager publisher jaggery app which is located outside of that jaggery app. The reason for the requirement is that this particular file is a sample documentation which we plan to distribute with API Manager and should be stored in a location which users can e