[XSL-LIST Mailing List Archive Home] [By Thread] [By Date]

RE: [xsl] Header/Footer asking.


Subject: RE: [xsl] Header/Footer asking.
From: Rod Humphris - FLPTN <rod.humphris@xxxxxxxxxxxxxx>
Date: Mon, 4 Aug 2003 12:36:16 +0100

Or you could just have a separate xslt file with named header and footer
templates in it, include/import this into your main xslt:

<xsl:include href="HnF.xslt"/>

and call it where you want its output: 

 <xsl:call-template name="footer"/>
</html>

This way you only need to write your header/footer templates once and any
changes you make to them will be reflected in all the xslt that use them,
which I would think is the main point of header/footers.

If you need your header and footer templates to react to the data you can
parameterize them.

Cheers

Rod


-----Original Message-----
From: Andrew Welch [mailto:AWelch@xxxxxxxxxxxxxxx]
Sent: 04 August 2003 12:09
To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx
Subject: RE: [xsl] Header/Footer asking.


> Hi!
> I would like to use a header/footer into an HTML  report which is
maded in
> XSL from a XML.
> Anybody know a way of how should I do that ?

HTML doesn't know about headers and footers, so I think you are out of
luck.  If your data is repetitive you could use CSS2's page-break-before
and page-break-after with some nifty xslt... but it's unlikely your data
will fit.

It is possible to 'hack' the windows registry to put in your own headers
on anything that gets printed, but if your app/computer crashes and
doesn't delete your custom header and footer, then anything that gets
printed from that machine will have them too (of course until you app is
closed cleanly :)

Ultimately I think the only way to go about this is to use xsl:fo to
pdf.  I think Im about to embark on a similar project, and I can forsee
dual maintenance issues.  I wonder how common it is to have xslt->html
for screen and xsl:fo->pdf for printing, and any probems that have
arisen?

cheers
andrew   

 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


________________________________________________________________________
This email has been scanned for all viruses by the MessageLabs Email
Security System. For more information on a proactive email security
service working around the clock, around the globe, visit
http://www.messagelabs.com
________________________________________________________________________


________________________________________________________________
Any opinions expressed in this email are those of the individual and not necessarily the Company. Unless expressly stated to the contrary, this email is not intended to give rise to a new, or affect an existing, contractual or other legal relationship.This email and any files transmitted with it, including replies and forwarded copies which may contain alterations) subsequently transmitted from the Company, are confidential and solely for the use of the intended recipient. The unauthorised use, disclosure or copying of this email, or any other information contained or attached,is prohibited and could, in certain circumstances, be a criminal offence.

If you have received this email in error please notify the sender as soon as possible.

This footnote also confirms that this email message has been swept for the presence of computer viruses.

www.focusdiy.co.uk
_________________________________________________________________

________________________________________________________________________
This email has been scanned for all viruses by the MessageLabs Email
Security System. For more information on a proactive email security
service working around the clock, around the globe, visit
http://www.messagelabs.com
________________________________________________________________________

 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list



Current Thread
Keywords