views:

170

answers:

1

I new to xml stuff, so I have no idea which api I should use in python. Till now I used xmlproc, but I heard it is not developed any more.

I have basically only one requirement: I want to validate against a dtd that I can choose in my program. I can't thrust the doctype thing.

Performance does not really matter, so I would like to use the most easy api that exists.

What to use? Have you guys a simple example?

+3  A: 

For my current project, I'm using lxml, which is fairly easy to use. Validation with DTD is described on this page

Steef
+1 for the lxml option
ChristopheD