Browse thread
XML library for validating MathML
[
Home
]
[ Index:
by date
|
by threads
]
[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
| Date: | -- (:) |
| From: | Vincent Hanquez <tab@s...> |
| Subject: | Re: [Caml-list] XML library for validating MathML |
On Wed, Sep 17, 2008 at 11:58:05AM -0700, Dario Teixeira wrote: > Given a string containing a mathematical expression in the MathML > markup, I need to verify that the expression is indeed valid MathML. > I am therefore looking for an XML library that can verify an expression > against a given DTD. > > Now, I have tried Xml-light, and the code I used is listed below. > Unfortunately, it fails when trying to parse MathML's DTD (it's the > standard DTD from the W3C). I have tried simpler DTDs, and it does work > with them; am I therefore correct in assuming that Xml-light can only > handle a particular version/subset of DTD features? I don't know about validation (i'll probably suggest looking at PXP tho), but xml-light is very bad for XML compliance. the library is (happily) parsing XML files that it shouldn't, which tell a lots concerning its validation abilities ... for example, the XML supported character range is not even checked: Xml 1.0 specification -- 2.2 Characters Char ::= #x9 | #xA | #xD | [#x20-#xD7FF] | [#xE000-#xFFFD] | [#x10000-#x10FFFF] others problems include (uncomplete list): - complete unicode un-awareness - funny & wrong entities handling -- Vincent