GIQUEL Magali wrote:
> Hi,
> I use tomcat4.0 and cocoon 2,
> after a click on a jsp page, i send a request on tamino which returns an
> xml document.
> My probem is that the URI I want to access is included in the sitemap and
> this uri has got parameters (id). These parameters come from hyperlinks on
> a jsp page.
> I don't known how to send these parameters from the jsp file to the
> sitemap.
>
> <map:match pattern="eBiz.html">
> <map:generate
> src="http://lanester:80/tamino/execLog?_xql=//wes:HISTORY[@ino:id={id}]"/>
> <map:transform src="eBizMonitor/journalFR.xsl"/>
> <map:serialize type="html"/>
> </map:match>
> magali
>
Basically it would look like:
<map:match pattern="eBiz.html">
<map:match type="request-parameter" pattern="id">
<map:generate
src="http://lanester:80/tamino/execLog?_xql=//wes:HISTORY[@ino:id%3D{1}]"/>
<map:transform src="eBizMonitor/journalFR.xsl"/>
<map:serialize type="html"/>
</map:match>
</map:match>
However you have to urlencode your query string and I don't know, how to do
it in the sitemap.
I started fro a different direction and used a XSL-Transformer and a cinclude
transformer.
<xsl:template match="xql:query">
<cinclude:include
src="http://vsc016.fiz-chemie.de/tamino/vsc1/vsc-header?_xql={java:java.net.URLEncoder.encode(string(.))}"
/>
</xsl:template>
You might use RequestGenerator, so sequence would be:
RequestGenerator -> my XSLT (modified) -> Cinclude -> your XSLT (modified)
-> HTML serializer
Regards
Martin Holz
---------------------------------------------------------------------
Please check that your question has not already been answered in the
FAQ before posting. <http://xml.apache.org/cocoon/faqs.html>
To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>