[jdom-interest] Embedding HTML in XML

Richard Waters rwaters at marimba.com
Mon Jun 26 11:14:11 PDT 2000

hi all,

i'm trying out a little servlet project with XML - i was previously using
the xerces api, but things have become so much easier after switching to
jdom. great job!

so maybe someone can help me with this problem: i have users submitting html
forms, the content of which is converted into some xml (with XMLOutputter),
and later rendered as html (using xalan). i'd like users to be able to enter
some html in those textboxes, and have that correctly rendered later.

the only way i came up with to do this is to parse the text submitted with
the html forms, create xml elements for the html elements i find, generate a
list with these elements and the text, and then use setMixedContent().
that's a pretty painful way to do it. since i'm pretty much a novice so far,
i'm hoping i'm just failing to see a much easier way to do this.

thanks a lot for any advice you can give,

More information about the jdom-interest mailing list