Creating XML in PHP with somewhat large data stored in Javascript

anbarasan_net

New Member
I have a somewhat large store of data in Javascript that I need to eventually turn into an XML file on the PHP server. It seems quite cumbersome to turn the data in a JSON object, send this to PHP through an ajax POST and then create an XML object with a PHP library and create the XML file. It seems that I would prefer to create some sort of XML object on the javascript and then send this to the PHP with a dojo/ajax call. Sadly I have not been able to find any good Dojo or Javascript libraries to create the XML and it seems like it would tedious and error prone to create the XML by hand. Is there a good way to create XML in Javascript? Am I go about this wrong? Should I just be sending all of the data as large JSON and then deciphering it in PHP?
 
Back
Top