<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=Content-Type content="text/html; charset=iso-8859-1">
<META content="MSHTML 6.00.2600.0" name=GENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=#ffffff>
<DIV><FONT face=Arial size=2>JDOM users:</FONT></DIV>
<DIV><FONT face=Arial size=2> I'm not sure if this is related to JDOM or
not but maybe someone has an idea:</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial size=2> I'm creating a web interface for editing XML
documents. The form submits to a servlet that reads the existing XML
document in and represents it with JDOM. I use setText() on the various
Elements to make changes based on the form data and then write out the new
XML file with XMLOutputter.output(). Some of the form fields contain XML
tags (for inline stuff like <italic> and <bold>). Somewhere in
the process those inline XML tags that are coming across the CGI are being
changed from <italic> to &lt;italic&gt;. This of course
causes problems because when the XML file is parsed these tags are seen as
strings rather than nodes.</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial size=2>I've used System.out to check the strings and I
don't see any entity references as far as the servlet is concerned. Maybe
System.out resolves them...</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial size=2>Is there anything in the
XMLOutputter.output() or Element.setText() methods that resolves these
characters to HTML entities? Any ideas? Suggestions?</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial size=2>Thanks</FONT></DIV></BODY></HTML>