Libxml2 - validate XML document against schema. Retrieve schema url from the actual XML file?

In theory you could use put an xsi:schemaLocation attribute in the XML file and let the XML processors find out where the XML Schema is.

Up vote 1 down vote favorite share g+ share fb share tw.

I need to validate a xml file against DTD schema. I found out that I need to pass the source of schema file for validation. Is that possible to make libxml2 find the declaration of schema in XML file and do the validation on its own, or do I have to retrieve the declaration manually?

Thanks in advance Michal xml validation schema dtd libxml2 link|improve this question edited Apr 16 '10 at 18:14Laurent Etiemble11.8k2929 asked Jan 20 '10 at 18:06migajek2,11311435 98% accept rate.

In theory you could use put an xsi:schemaLocation attribute in the XML file and let the XML processors find out where the XML Schema is. The status of xsi:schemaLocation in libXML is unclear, see this bug report: bugzilla.gnome.org/show_bug.cgi?id=157205. It seems implemented in the library itself but not enabled in the provided xmllint util.

I cant really gove you an answer,but what I can give you is a way to a solution, that is you have to find the anglde that you relate to or peaks your interest. A good paper is one that people get drawn into because it reaches them ln some way.As for me WW11 to me, I think of the holocaust and the effect it had on the survivors, their families and those who stood by and did nothing until it was too late.

Related Questions