What, specifically, are you trying to do? It's unusual you'd need to do this.
Bart Stanz
Greenhorn
Joined: Feb 06, 2010
Posts: 13
posted
0
Do you mean taking form output and saving it as an xml file?
www.bartium.com
Edward Chen
Ranch Hand
Joined: Dec 23, 2003
Posts: 758
posted
0
David Newton wrote:What, specifically, are you trying to do? It's unusual you'd need to do this.
Using DWR Ajax to call server, I want to send xml in and get xml out. so I need to get user form input and convert it into xml. I did some research, found XForm will achieve this, but XForm is not that much supported in browser. Do we have a javascript library, like JQuery.., to convert this ?
Thanks.
Eric Pascarello
author
Rancher
Joined: Nov 08, 2001
Posts: 15357
6
posted
0
Reason you do not send up a normal form submission to the server?
Eric
Edward Chen
Ranch Hand
Joined: Dec 23, 2003
Posts: 758
posted
0
Eric Pascarello wrote:Reason you do not send up a normal form submission to the server?
to achieve a kind of SOA, decouple UI from server, in the service side, we use XML-in-and-XML-out, then we will have no any pain to develop a desktop UI.
My design is like this, service side accept XML in, then use XStream map to Object, finish business logic, use XStream decode Object to XML and return it to user. In html client, we use DWR to call this service, In Desktop client, use web service to call service.
Usually we can easily get user form input in JSon format, but this is not XML, then in service side, I have to use another convert...
Although really I'd do this on the server side by making JSON and XML request handlers (and HTML as well, in case the client has JavaScript turned off).
Eric Pascarello
author
Rancher
Joined: Nov 08, 2001
Posts: 15357
6
posted
0
I agree with David, if you need to do the XML, that means your users will have to have JavaScript enabled.
I still think that it should be done on the server, seems logical to me to do it there.
How are you going to do the validation and such with the server? Seems like you are making more work to make it simplifier to make a client app.