Mark, for one technique, see my message from about 12 hours ago ("sitemap
logic depending on pipeline content").
Aside from the technique in Conal's message, this is generally not possible. The technical reason is that a pipeline is assembled before processing starts. Only certain pipeline elements can influence construction of a pipeline (matchers, selectors, actions, and flow). This is an intentional design decision to help enforce separation of the model (content) from "controller" and presentation (selection of stylesheet being one aspect of those). Another aspect to this is caching which would be impossible (or useless) if processing had to start in order to figure out if a cached response had already been generated.
You can "peek" into the intended source file with an action or flow, or even possibly one of the xml-based input sources to accomplish the same sort of thing. If you have the flexibility to restructure your data, you can also consider finding some other way to store and signal that information.
HTH, Geoff
-----Original Message----- From: Mark Lundquist [mailto:[EMAIL PROTECTED] Sent: Sunday, 11 January 2004 18:37 To: [EMAIL PROTECTED] Subject: xml select own stylesheet?
Dear People Who Know More About Cocoon Than I Do,
I would like to determine which stylesheet to call for (i.e., the src in a <map:transform>) based on the value of an element in the XML source data itself. That would mean the pipeline has to be able to see into the stream it's processing, right? Maybe that's totally normal and I just don't know how to do it...
So, is there a way to query the source XML from within the sitemap?
Thanks for putting up with me noob questions :-)
~mark
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
