cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jörn Heid <>
Subject AW: XML selector
Date Thu, 06 Sep 2001 08:08:40 GMT
I don't think this is possible as of SAX: When the first element is
generated from your xsp the pipeline has to be determined.
What you want to have is that the pipeline depends on the dom tree (C1). For
that, you have to find another way.

The simplest solution for your problem, I think, is to write an action which
puts the information you desires into the sitemap. Then you can use the
ParameterSelectorFactory to determine the transformation.

Other opinions? Am I right?


-----Urspr√ľngliche Nachricht-----
Von: Paolo []
Gesendet: Donnerstag, 6. September 2001 09:47
An: Cocoon-Users
Betreff: XML selector

I need to select the correct stylesheet checking some XML flags of the
pipeline. Something like this (look at the XML selector):

	<map:match pattern="*">
 	   <map:generate type="serverpages" src="db.xsp"/>

	   <map:select type="xml " node="/test/test2/flag">
	      <!-- you could insert parameters here as well -->
	      <map:when test="normal">
   	         <map:transform src="stylesheets/normal.xsl"/>
	      <map:when test="special">
   	         <map:transform src="stylesheets/special.xsl"/>
   	         <map:transform src="stylesheets/default.xsl"/>

   	   <map:transform src="stylesheets/dynamic-page2html.xsl"/>

Remember I don't want to do that in the XSP generator because of leaving
separated logic and view of my page.

Any hint for me?

Paolo Scaffardi

Please check that your question has not already been answered in the
FAQ before posting. <>

To unsubscribe, e-mail: <>
For additional commands, e-mail: <>

To unsubscribe, e-mail:
For additional commands, email:

View raw message