How to get the outer xml from an jquery root object?

How to get the outer xml from an jquery root object?

Hi there,

i pumped an xml string into jquery and want to print out the entire xml document.
Something like this:

var jxml = $("<servers><server>A</server><server>B</server></servers>");

Now i do some modifications on the dom or not... doesent matter.

And then i simply want to print out the entire jxml content but i have no idea how to do this?
Something like this:

// Just simply alert out the outer xml content
alert($(jxml).outerXML());




I tested the $(jxml).text(), $(jxml).html() and i got always an empty string without any content at all.
I am new to jquery maybe this is just some simple thing.... hopefully.



What i want to is, reading out an xml string from some kind of local store (Plain xml text).
Parse this with the DOMParser as XML (I would use the xmlDOM plugin for jquery).
Modify something on that object and write it back as Plain xml text to the local storage.



Thanks in regards,
Finalspace