G
gregmcmullinjr
I am wondering if there is a way to use a DTD or Schema to instruct an
XML parser to ignore tags that are not defined.
That is, if my list of acceptable tags is <body> and <content>, then in
the following example:
<body>
We may have some text <b>and some <u>other tags</u></b>
<content> but I want the text and undefined tags to be part of the
text-node
of the body tag.
</content>
</body>
So the tree would be like:
<body>
#Text
<content>
#Text
</content>
</body>
I want the first text node to contain "We may have some text <b>and
some <u>other tags</u></b>"
Is there some way of doing this with Schemas or DTDs? Or perhaps using
a stylesheet?
Using a stylesheet I would need to do find a way of matching all tags
that arent in a certain list and then re-writing them with $lt;
entities I suppose, but I'm really not sure what the best way to do
this is.
Any help is appreciated,
Greg
XML parser to ignore tags that are not defined.
That is, if my list of acceptable tags is <body> and <content>, then in
the following example:
<body>
We may have some text <b>and some <u>other tags</u></b>
<content> but I want the text and undefined tags to be part of the
text-node
of the body tag.
</content>
</body>
So the tree would be like:
<body>
#Text
<content>
#Text
</content>
</body>
I want the first text node to contain "We may have some text <b>and
some <u>other tags</u></b>"
Is there some way of doing this with Schemas or DTDs? Or perhaps using
a stylesheet?
Using a stylesheet I would need to do find a way of matching all tags
that arent in a certain list and then re-writing them with $lt;
entities I suppose, but I'm really not sure what the best way to do
this is.
Any help is appreciated,
Greg