cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Hans Ulrich Niedermann <niederm...@isd.uni-stuttgart.de>
Subject Re: Choosing an XSL dynamically
Date Wed, 24 May 2000 13:26:22 GMT
Ken Beyer <kab@metatec.com> writes:

> <xsp:page language="java"
> xmlns:xsp="http://www.apache.org/1999/XSP/Core">

You don't need XSP to select a XSL stylesheet dynamically. My solution
doesn't need XSP. 

[ ... ]

>    <xsl:processing-instruction
> name="cocoon-process">type="xslt"</xsl:processing-instruction>
>    <xsl:processing-instruction name="xml-stylesheet">
>    href="test.<xsl:value-of select="$portal"/>.xsl"
>    type="text/xsl"
>    </xsl:processing-instruction>

I'd prefer to check the values of $portal and match them agains a
fixed list. Else any remote user may try to find out what your XSL
files do, what your XML file contains (?portal=test.broker.xsl)
etc. pp.

Uli
-- 
Hans Ulrich Niedermann      <niedermann@normans.isd.uni-stuttgart.de>
Systemadministration         http://www.normans.isd.uni-stuttgart.de/
Institut für Statik und Dynamik der Luft- und Raumfahrtkonstruktionen

Mime
View raw message