[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]
Subject: Re: [docbook-apps] HTML - need header on all pages except title page
Hi John, The titlepage chunk is generated for the root element of the document, so you can use a test like this: <xsl:if test="ancestor::*"> This xpath expression will return all the ancestor nodes for the current element being processed. That node-set will be empty only for the root element of the document, which is the one that generates the titlepage chunk. In an xpath expression, an empty node set is interpreted as false. Regarding the titlepage.mode, that's there to support rearranging the elements on the titlepage. Normally XSL processes elements in document order. To prevent that, there are empty templates that match on every titlepage element. That turns off the "normal" processing of those elements. The subsystem that uses the titlepage spec file and generated xsl file instead uses its own mode to process the titlepage elements, in the order specified in the spec file. Bob Stayton Sagehill Enterprises bobs@sagehill.net ----- Original Message ----- From: "John Brown" <johnbrown105@hotmail.com> To: <docbook-apps@lists.oasis-open.org> Sent: Friday, July 11, 2008 4:06 PM Subject: [docbook-apps] HTML - need header on all pages except title page > Hello All, > > I have a title page with a mediaobject on it. I want that same > mediaobject to apear on all the pages. I modified a copyright footer > example from Bob Stayton's book like this: > > <xsl:template name="user.header.content"> > <xsl:apply-templates select="//d:info/d:mediaobject" > mode="titlepage.mode"/> > </xsl:template> > > I don't fully understand this (specifically, I don't know what the > mode="titlepage.mode" part does), but it works. However, the image now > appears twice on the title page. > > Maybe I could fix this by just removing the mediaobject > from the title page (would I then have to change the mode="..." to > something > else?), but how can the template find out if it is in a title page, i.e., > > <xsl:template name="user.header.content"> > <xsl:if test="TEST-FOR-TITLE-PAGE=false"> > <xsl:apply-templates select="//d:info/d:mediaobject" > mode="titlepage.mode"/> > </xsl:if> > </xsl:template> > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: docbook-apps-unsubscribe@lists.oasis-open.org > For additional commands, e-mail: docbook-apps-help@lists.oasis-open.org > > >
[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]