I have a search server that provides a test page where I can input a query and it returns the results in XML. I want to be able to go through the results in a more user frie
I would have added this in a comment, but I don't have the relevant reputation. There are two things that I would check. Especially if this is working on a string, and not a file from the server like you said
If you aren't getting a string, you can do an ajax request to get the text from the xml. And then load that as your new xml var.
And if you really just wanted to make your xml user friendly, I would suggest checking out
http://code.google.com/p/vkbeautify
and
http://google-code-prettify.googlecode.com/svn/trunk/README.html
Those should maintain the xml format while stylizing it to make it easy to read. Plus, you won't have to mess with greasemonkey, and can instead just use javascript.