Skip to content
Advertisement

Tag: xhtml

Validate (X)HTML in Python

What’s the best way to go about validating that a document follows some version of HTML (prefereably that I can specify)? I’d like to be able to know where the failures occur, as in a web-based validator, except in a native Python app. Answer XHTML is easy, use lxml. HTML is harder, since there’s traditionally not been as much interest

Advertisement