Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Java > Controlling XML elements order

Reply
Thread Tools

Controlling XML elements order

 
 
Tomer Ben-David
Guest
Posts: n/a
 
      09-27-2004
Hi I'm returning an XML to my clients (SOAP). Now I want to order the
items in my XML (I dont want my clients to sort it) is there any API
in DOM that I can use for sorting the elements some way ? or simply
preserving the sort order of that that I added items to the DOM tree?
(I'm adding the items in a sorted way however when I look at the XML
generated its not sorted)
 
Reply With Quote
 
 
 
 
LX-i
Guest
Posts: n/a
 
      09-30-2004
Tomer Ben-David wrote:
> Hi I'm returning an XML to my clients (SOAP). Now I want to order the
> items in my XML (I dont want my clients to sort it) is there any API
> in DOM that I can use for sorting the elements some way ? or simply
> preserving the sort order of that that I added items to the DOM tree?
> (I'm adding the items in a sorted way however when I look at the XML
> generated its not sorted)


You might be able to implement an XSLT stylesheet that outputs XML, and
use the <xsl:sort> element.


--
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ~~~~~~~~~~~~~
~ / \ / ~ Live from Montgomery, AL! ~
~ / \/ o ~ ~
~ / /\ - | ~ http://www.velocityreviews.com/forums/(E-Mail Removed) ~
~ _____ / \ | ~ http://www.knology.net/~mopsmom/daniel ~
~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~
~ I do not read e-mail at the above address ~
~ Please see website if you wish to contact me privately ~
~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~
~ GEEKCODE 3.12 GCS/IT d s-:+ a C++ L++ E--- W++ N++ o? K- w$ ~
~ !O M-- V PS+ PE++ Y? !PGP t+ 5? X+ R* tv b+ DI++ D+ G- e ~
~ h---- r+++ z++++ ~
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ~~~~~~~~~~~~~

 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Controlling tab order with JavaScript Mark Reginald James Javascript 22 09-28-2005 08:38 AM
Validation Summary - controlling order that error messages are listed Chris Rumsey via .NET 247 ASP .Net Web Controls 0 09-15-2004 06:45 PM
Validation Summary controlling the order of messages Chris Rumsey via .NET 247 ASP .Net 1 09-06-2004 08:18 PM
controlling "return key" behavior with multiple "form-elements" Holger (David) Wagner ASP .Net 1 08-17-2004 08:08 PM
controlling execution order of servlet filters Angus Parvis Java 1 08-04-2004 02:50 PM



Advertisments