[Freeswitch-users] Parsing XML files from Spidermonkey

Alberto Escudero aep.lists at it46.se
Thu Apr 8 12:04:18 PDT 2010


Hi,

After one year using FS i am starting to like XML so i am trying to get
a Javascript script to read local XML files.

I am using the XML method and getting Syntax errors from spidermonkey

While something like this works:
xmldata = new XML("<tag>foo</tag>");

I have not been able to read and parse XML local files, using File or FileIO
methods

A simple example like this returns Syntax error.
var foo = apiExecute ("show", "channels as xml");
xmldata = new XML(foo);

Has anyone managed to use the XML method from spidermonkey to read a XML
stored file?

There are some E4X bugs around and i wonder if those are the cause of the
"Syntax Error" feedback even reading a very basic XML file
-- 
Stopping junk mailers is good for the environment






More information about the FreeSWITCH-users mailing list