You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cocoon.apache.org by James Cummings <Ja...@computing-services.oxford.ac.uk> on 2003/12/18 10:56:12 UTC
Re: users Digest 17 Dec 2003 21:47:17 -0000 Issue 2422
> James,
>
> I would suggest using the cinclude transformer after your XSLT. Simply have your XSLT insert the
> ci:include elements for the documents you wish to include, and then add <map:transform
> type="cinclude"/> after your transformer. XSLT has the document() function, but that's not recommended.
>
> > -James
>
> Regards,
>
> Tony
>
Tony,
Thanks for the suggestion and I'll check it out. What I've ended up
doing temporarily is:
<xsl:copy-of select="document('../../html/header.xml')"/>
Why isn't this recommended? It seems to fail absolutely fine with
no side effects if header.xml doesn't exist or is not well-formed.
(i.e. it just isn't included). Is there something bad about it
I'm not seeing?
I'm assuming using <ci:include> I'll have to do something like:
<ci:include xmlns:ci="http://apache.org/cocoon/include/1.0"
src="../../html/header.xml"/>
(or maybe context://header.xml)
And include <map:transform type="cinclude"/> before or after the
initial transformation.
-James
---
Dr James Cummings, Oxford Text Archive, James.Cummings@ota.ahds.ac.uk
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org
Re: users Digest 17 Dec 2003 21:47:17 -0000 Issue 2422
Posted by "J.Pietschmann" <j3...@yahoo.de>.
James Cummings wrote:
> <xsl:copy-of select="document('../../html/header.xml')"/>
>
> Why isn't this recommended? It seems to fail absolutely fine with
> no side effects if header.xml doesn't exist or is not well-formed.
> (i.e. it just isn't included). Is there something bad about it
> I'm not seeing?
Changing the header.xml does not invalidate the cached result,
which is sent to the browser until the main source, the style
sheet or any other component recognized by the caching mechanism
changes. There are other reasons as well.
J.Pietschmann
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org