Hi,

I currently have a request selector working to choose which xsl to use based on a 
query string in the request. I built this using the method recommend repeatedly in the 
mailing list archives and it works but I would like it to simply test whether there is 
a style paramater and use it if there is, or otherwise use the default. Having to 
specify each possible stylesheet in a seperate case is annoying and wasteful. Is there 
another way to do this?

thanks in advance.
Jo

PS. here is an example of what I am using at present

   <map:match pattern="**.xml">
    <map:generate src="{1}.xml"/>
          <map:select type="request">
            <map:parameter name="parameter-name" value="style"/>
           <map:when test="special_one.xsl">
            <map:transform src="special_one.xsl"/>
          </map:when>
           <map:when test="special_two.xsl">
            <map:transform src="special_two.xsl"/>
          </map:when>
           <map:when test="special_three.xsl">
            <map:transform src="special_three.xsl"/>
          </map:when>
          <map:otherwise>
            <map:transform src="default.xsl"/> 
          </map:otherwise>
         </map:select>
    <map:serialize/>
   </map:match>

---------------------------------------------------------------------
Please check that your question  has not already been answered in the
FAQ before posting.     <http://xml.apache.org/cocoon/faq/index.html>

To unsubscribe, e-mail:     <[EMAIL PROTECTED]>
For additional commands, e-mail:   <[EMAIL PROTECTED]>

Reply via email to