cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Stefan Shoeman" <stefan.shoe...@googlemail.com>
Subject Re: How to do XSLT-transformations on a SAX-stream?
Date Fri, 13 Apr 2007 12:05:24 GMT
Thank you Jeroen, i've managed it.

--
Best Regards,

Stefan Shoeman

2007/4/12, Jeroen Reijn <j.reijn@hippo.nl>:
> Hi Stefan,
>
> yes you can use an XSL for that. Just add the XSLT after your generation step where you
have both the query and the parameter elements in the pipeline. You will be able to put the
value inside the sql query.
>
> Your transformer does not always need an xslt (src='') for processing because you can
also modify/parse the sax stream with your own custom transformer, but an XSLT is a bit easier.
>
> Kind regards,
>
> Jeroen Reijn
>
>         -----Oorspronkelijk bericht-----
>         Van: Stefan Shoeman [mailto:stefan.shoeman@googlemail.com]
>         Verzonden: do 12-4-2007 15:58
>         Aan: users@cocoon.apache.org
>         CC:
>         Onderwerp: How to do XSLT-transformations on a SAX-stream?
>
>
>
>         Hello *,
>
>         I would like to paste a parameter (e.g. 23) into some sql statements.
>         Both of them are in a SAX-stream (normal pipeline), which looks like
>         this:
>
>         ----------------------------------8<-------------stream-----------------------
>         <sql:query>
>                         SELECT p_users.item FROM p_users WHERE p_users.user-id =
>                         <xsl:value-of select="/par:parameters/par:parameter1" />
>         </sql:query>
>
>         <par:parameters>
>           <par:parameter1>
>            23
>           </par:parameter1>
>         </par:parameters>
>         ---------------------------------->8-------------stream-----------------------
>
>         How can I set a XSLT-transformation in the sitemap, which gets the
>         parameter from the stream (It always needs a xslt-file (src=...) for
>         processing)?
>
>         Are there any better solutions, to get the parameter into the query?
>         (The query was included by xinclude.)
>
>         Thanks for reading...
>
>         --
>         Best Regards,
>
>         Stefan Shoeman
>
>         ---------------------------------------------------------------------
>         To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
>         For additional commands, e-mail: users-help@cocoon.apache.org
>
>
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org


Mime
View raw message