Recently I came across the situation where I created a webpage on which I wanted to include some raw XML data in a <textarea> so the user could see that XML data including all tags and stuff. What made the setup special was, that in this scenario I didn’t just put a predefined XML formatted data inside the textarea, but the XML data was supposed to be inserted into the webpage (into the textarea) on the client-side via Javascript.
(In order to give you a little bit more information about the whole picture: the source XML data – to be inserted on the fly – might change and should be able to be updated without reloading the whole page)
Jan 202010