Hi Robert,
1) The epub stylesheet generates XHTML, which is in the XHTML namespace:
xmlns="http://www.w3.org/1999/xhtml"
You will need to add that namespace attribute to the root element of your
included HTML. If you don't then the processor marks it as being outside of
the XHTML namespace.
2) This is a bug in the chunker.xsl stylesheet file, where it fails to omit
the namespace declaration for "saxon" namespace. I'll fix that.
Bob Stayton
Sagehill Enterprises
----- Original Message -----
From: "Robert Nagle" <>
To: <>
Sent: Wednesday, October 14, 2009 11:30 AM
Subject: [docbook-apps] why do user templates generate empty xmlns
attributes?
> When on the advice of Bob Stayton's last email
> (http://lists.oasis-open.org/archives/docbook-apps/200910/msg00021.html)
> I created a custom template for my customization layer , I notice
> something strange.
>
>
>
> </head><body><p xmlns=""><b>Hi Mom!</b></p><div class="chapter"
> title="Would Kafka have kept a weblog?"><div
> class="titlepage"><div><div><h1 class="title"><a
> xmlns:saxon="http://icl.com/saxon" id="nt001"/>Would Kafka have kept a
> weblog? </h1></div></div></div>
>
> Two questions:
>
> 1)why does <p xmlns=""> show an empty value. (That actually makes the
> code invalid and the resulting .epub invalid as well).
>
> 2)what is going on here: <a xmlns:saxon="http://icl.com/saxon"> Why
> is this namespace value there in the first place?
>
> I notice that these kinds of weirdness/errors pop up all the time
> whenever I try to put an xsl:template statement in my customization
> layer file. I could live with the second error, but not the first.
> Any idea what is causing this to happen?
>
>
>
> My customization layer is pretty vanilla. It's for epub/chunked html
> output.
>
> ********************
> <?xml version="1.0" encoding="UTF-8"?>
> <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
> version="1.0">
> <xsl:import
> href="http://docbook.sourceforge.net/release/xsl/1.75.2/epub/docbook.xsl"/>
> <xsl:param name="epub.metainf.dir">META-INF/</xsl:param>
> <xsl:param name="epub.oebps.dir">OEBPS/</xsl:param>
> <xsl:param name="use.id.as.filename">1</xsl:param>
> <xsl:param name="html.stylesheet">first.css</xsl:param>
> <!--<xsl:param name="show.comments">1</xsl:param>-->
> <xsl:param name="label.from.part" select="0"></xsl:param>
> <xsl:param name="chapter.autolabel">0</xsl:param>
> <xsl:param name="part.autolabel">0</xsl:param>
> <xsl:param name="img.src.path">images/</xsl:param>
> <xsl:template name="user.header.content">
> <p><b>Hi Mom!</b></p>
> </xsl:template>
> </xsl:stylesheet>
> *******************
>
> --
> Robert Nagle
> htpt://www.robertnagle.info
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail:
> For additional commands, e-mail:
>
>
>