cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jeremy Quinn <>
Subject input modules
Date Sat, 29 Mar 2003 17:32:37 GMT
Hi All

Is it possible to use a value from a matcher in an input module?
(I asked about this a while ago, there was some interest, but I don't 
remember what was resolved).

I need to take a URL coming into a Sitemap, pass it to an input module 
and use the returned value in the @src of a generator. ie. I am using 
an XML file to 'translate' URLs.

I have a 'linkmap' that maps incoming URL stubs to file locations (and 
describes the structure of a site).

A linkmap looks something like this:

   <map lang="en">
     <ref xl:label="home" xl:href="home.xml" xl:title="blah">
       <ref xl:label="work" xl:href="work/home.xml" xl:title="blah">
         <ref xl:label="schematic" xl:href="work/schematic.xml" 
       <ref xl:label="faq" xl:href="faq/home.xml" xl:title="blah">
         <ref xl:label="faq.strech" xl:href="faq/strech.xml" 
           <name>Dil Add Freeflow</name>

With a pipeline like this:

<map:match pattern="*">
	<map:generate src="{linkmap:{1}}"> ???????

How do you pass the "{1}" into the input module that will look up the 
URL (using XPath) in the LinkMap?

Thanks for any help

regards Jeremy

View raw message