Menu

#43 CSS links should include type=

Current_release
closed
5
2014-07-02
2012-01-21
No

Css links in the generated HTML files are missing the type= attributes.

Discussion

  • Steven Calderwood

    This is also an issue for the Kindle transform because at least on the original Fire and Kindle 4 devices without "type='text/css'" on the link tag, then the external CSS isn't processed. Here's the fix. Include this in html2xhtmlImpl.xsl:

     \<xsl:template mode="html2xhtml" match="link/@type\[.='text/css'\]" priority="20" \="">\<xsl:copy \="">\</xsl:copy></xsl:template>

    Also in the attached file since I fail at markdown.

    Right now I only have that matching for our Kindle output, but I would think it would be better to include it in the base epub transform's html2xhtmlImpl.xsl since the presence of the type attribute doesn't cause epub validation failure.

    The inclusion of "link" in the match might be superfluous (I don't know of other cases where an @type value would be "text/css" but I include it in case there are such cases).

     

    Last edit: Steven Calderwood 2012-10-08
  • W. Eliot Kimber

    W. Eliot Kimber - 2014-07-02
    • status: open --> closed
     
  • W. Eliot Kimber

    W. Eliot Kimber - 2014-07-02

    Released in 0.9.19RC12

     

Anonymous
Anonymous

Add attachments
Cancel