display pretty xml in a htmlviewer?

Anyone got a code snipped that shows how to display an xml ‘tree’ in an html viewer?
You know… With nice indentation and +/- controls on each element?