![]() |
DTD validation and xmlproc
I found Python code to validate a XML document basd on DTD file
layout. The code uses the 'xmlproc' package and these module loading steps from xml.parsers.xmlproc import xmlproc from xml.parsers.xmlproc import xmlval from xml.parsers.xmlproc import xmldtd Unfortunately, the xml package no longer seems to hold the xmlproc module. As a standalone the xmlproc module seems to be no longer maintained and was subsumed in PyXML a few years ago and that package is no longer maintained (as best I can tell, or maybe was subsumed in the base Python 2.x packages) My problem is I can not get the old xmlproc package files that i did find to work with Python 2.5. I am willing to learn and use new xml procedures, but I found nothng pre-written to validate agaisnt a given DTD file. Any advice would be welcome, even a good tutorial on XML validation usiog Python. |
Re: DTD validation and xmlproc
mmm wrote:
> I am willing to learn and use new xml procedures, but I found nothng > pre-written to validate agaisnt a given DTD file. > > Any advice would be welcome, even a good tutorial on XML validation > usiog Python. Regarding that part, try lxml. http://codespeak.net/lxml http://codespeak.net/lxml/tutorial.html http://codespeak.net/lxml/validation.html Stefan |
Re: DTD validation and xmlproc
> Regarding ... try lxml. > http://codespeak.net/lxmlhttp://code...alidation.html > Thx Stefan, it seems that lxml does everything I need. I have not figured out all of the bells and whistles but the tutorials are getting me up to speed. Based 2 days of trial, I can recommend lxml without reservation. |
| All times are GMT. The time now is 12:03 PM. |
Powered by vBulletin®. Copyright ©2000 - 2013, vBulletin Solutions, Inc.
SEO by vBSEO ©2010, Crawlability, Inc.