title: Convince Firefox to parse HTML embedded in XML (after XSL is applied)
body: <p>I have some XML files of this form:</p>
  
  <pre><code>&lt;?xml version="1.0" encoding="utf-8"?&gt;
  &lt;?xml-stylesheet type="text/xsl" href="biomirror.xsl"?&gt;
  &lt;Thread&gt;
      &lt;Title&gt; Some thread title &lt;/Title&gt;
      &lt;Posts&gt;
          &lt;Post&gt;
              &lt;Author&gt; Me &lt;/Author&gt;
              &lt;Body&gt;
                  This is the post body, which &lt;b&gt;may&lt;/b&gt; have embedded XHTML, including all sorts of things like:&lt;br /&gt;
                  &lt;div class="quote"&gt;Quotes&lt;/div&gt;
                  I know it's XHTML, though, the program spitting out XML verifies that.
              &lt;/Body&gt;
          &lt;/Post&gt;
      &lt;/Posts&gt;
  &lt;/Thread&gt;
  </code></pre>
  
  <p>I need to format them into readable threads, so I'm using a CSS stylesheet and an XSL stylesheet. The CSS works, I know for a fact there's nothing wrong with that. My problem seems to be with the XSL, as any embedded XHTML isn't being parsed by Firefox. In IE it works perfectly and comes out with proper formatting, but in Firefox it's entirely plain-text. I assume that has to do with it being escaped before being output, but I can't figure out how to prevent that.</p>
  
  <p>XSL is:</p>
  
  <pre><code>&lt;?xml version="1.0" encoding="utf-8"?&gt;
  &lt;xsl:stylesheet version="2.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"&gt;
  &lt;xsl:output 
    omit-xml-declaration="yes" 
    method="xml" 
    media-type="application/xhtml+xml" 
    indent="no" 
    doctype-public="-//W3C//DTD XHTML 1.0 Transitional//EN"
  /&gt;
  &lt;xsl:template match="Posts"&gt;
  &lt;xsl:for-each select="Post"&gt;
      &lt;tr xmlns="http://www.w3.org/1999/xhtml" class="Post"&gt;
        &lt;td&gt;
          &lt;div&gt;
            &lt;table width="100%" cellpadding="0" cellspacing="0"&gt;
              &lt;tr&gt;
                &lt;td class="Author"&gt;
                  &lt;xsl:value-of select="Author"/&gt;
                &lt;/td&gt;
                &lt;td class="Date"&gt;
                  Post &lt;xsl:value-of select="PostID"/&gt; 
                  &lt;xsl:choose&gt;
                    &lt;xsl:when test="count(LastPost) &gt; 0"&gt;
                      (lastpost)
                    &lt;/xsl:when&gt;
                  &lt;/xsl:choose&gt; at &lt;xsl:value-of select="Date"/&gt;
                &lt;/td&gt;
              &lt;/tr&gt;
            &lt;/table&gt;
          &lt;/div&gt;
          &lt;div class="Body"&gt;
             &lt;xsl:copy-of select="Body" /&gt;
          &lt;/div&gt;
          &lt;xsl:choose&gt;
            &lt;xsl:when test="count(Sig) = 1"&gt;
              &lt;div class="Sig"&gt;
                &lt;xsl:value-of disable-output-escaping="yes" select="Sig"/&gt;
              &lt;/div&gt;
            &lt;/xsl:when&gt;
            &lt;xsl:when test="count(Sig) = 0"&gt;
              &lt;div class="SigFooter"&gt; &lt;/div&gt;
            &lt;/xsl:when&gt;
          &lt;/xsl:choose&gt;
        &lt;/td&gt;
      &lt;/tr&gt;
  &lt;/xsl:for-each&gt;
  &lt;/xsl:template&gt;
  
  &lt;xsl:template match="Thread"&gt;
    &lt;html xmlns="http://www.w3.org/1999/xhtml"&gt;
      &lt;head&gt;
          &lt;xsl:choose&gt;
            &lt;xsl:when test="count(Title) = 1"&gt;
              &lt;title&gt;
                &lt;xsl:value-of select="Title"/&gt;
              &lt;/title&gt;
            &lt;/xsl:when&gt;
          &lt;/xsl:choose&gt;
          &lt;link href="resources/main.css" rel="stylesheet" type="text/css" /&gt;
      &lt;/head&gt;
      &lt;body&gt;
        &lt;table class="Thread" align="center" width="90%" height="95%" cellpadding="2em"&gt;
          &lt;tr&gt;
            &lt;td colspan="3"&gt;
              &lt;div class="Title"&gt;
            &lt;xsl:value-of select="Title"/&gt;
                &lt;br /&gt;
                &lt;a href="whatis.xml"&gt;
                  &lt;img src="resources/banner.png" /&gt;
                &lt;/a&gt;
              &lt;/div&gt;
            &lt;/td&gt;
          &lt;/tr&gt;
          &lt;xsl:apply-templates select="Posts"/&gt;
          &lt;tr height="100%"&gt;
           &lt;td valign="bottom"&gt;
         &lt;div class="Footer"&gt;
               Footer message n stuff
             &lt;/div&gt;
           &lt;/td&gt;
          &lt;/tr&gt;
        &lt;/table&gt;
      &lt;/body&gt;
    &lt;/html&gt;
  &lt;/xsl:template&gt;
  </code></pre>
  
  <p></p>
  
  <p>It's a bit of a hack and any odd attributes I blame on Visual Studio. This is my first time messing around with XSL (relatively familiar with XML, though), so I haven't the foggiest what to do to fix this. :)</p>
  
  <p>Now, I read this question:
  <a href="https://stackoverflow.com/questions/1105176/xslt-parsing-html-embedded-in-xml">XSLT: Parsing HTML embedded in XML?</a>
  and tried to integrate that into my XML and XSL (as shown above). Still doesn't work in Firefox, though.</p>
  
  <p><strong>Edit:</strong> Also, I tried both xsl:value-of and xsl:copy-of to output the content. Value-of outputs plain-text and respects my formatting (from the CSS), copy-of outputs plain-text and ruins my formatting (drops back to body formatting, disregarding divs and table).</p>
  
  <p><strong>Edit2:</strong> Revised XSL to reflect suggestions from answers. Formatting is fine, but the embedded tags are still coming out as text, not being interpreted.</p>