added support for equations in export of html
more error handling for domdiff