'Return the contents of this tag, rendered to html, as an etree element.'

def get_html(self):

    html = ('<html><html>%s</html><html>%s</html></html>' % (self.mathstr, saxutils.escape(self.xml.tail)))
    try:
        xhtml = etree.XML(html)
    except Exception as err:
        if self.system.DEBUG:
            msg = ('<html><div    class="inline-error"><p>Error    %s</p>' % str(err).replace('<', '&lt;'))
            msg += ('<p>Failed    to    construct    math    expression    from    <pre>%s</pre></p>' % html.replace('<', '&lt;'))
            msg += '</div></html>'
            log.error(msg)
            return etree.XML(msg)
        else:
            raise
    return xhtml
