You might want to check out CodeMirror , which has XML syntax highlighting, autocomplete, tag closure, and some other great features.
I'm not sure that CodeMirror includes XML validation as such, but it shouldn't be very difficult to add if you can just use XmlHttpRequest to submit content to the XML validation online service. >
source share