Client-side HTML processing with JavaScript support.
Project description
This code is neither mature nor maintained, and should not be used. It remains here only for the benefit of others who might want to do something similar.
DOMForm is a Python module for web scraping and web testing. It knows how to evaluate embedded JavaScript code in response to appropriate events. DOMForm supports both the ClientForm HTML form interface and the HTML DOM level 2 interface (note that ATM the DOM is written to an out-of-date version of the specification, and has some hacks to get it to work with ‘DOM as deployed’). The ClientForm interface makes it easy to parse HTML forms, fill them in and return them to the server. The DOM interface makes it easy to get at other parts of the document, and makes JavaScript support possible. The ability to switch back and forth between the two interfaces allows simpler code than would result from using either interface alone. DOMForm is partly derived from several third-party libraries. JavaScript support currently depends on Mozilla’s GPLed spidermonkey JavaScript interpreter (which is available separately from Mozilla itself) and python-spidermonkey.