> From: Matthew Hailstone [mailto:[EMAIL PROTECTED]]
> 
> > > From: Matthew
> > >
> Scenario:
>       Homepage XSP generates an initial form.
>       Parameters are set.
>       I would like to then access my sub-sitemap URI space depending
> on the parameter values.
>       Ex.
>       eval/first/first if parameter value is 1
>       eval/second/second if parater value is 2
> 
>       Is this possible by doing the following?

Yes, it's possible.

What Cocoon version do you use? Update either cocoon or just sitemap.xsl
with the latest one from the cvs, cocoon_2_0_3_branch.

Vadim

...

> Here is my latest try:
> 
>     <map:pipeline>
>       ...
>       <map:select type="request-parameter">
>         <map:parameter name="parameter-name" value="test-name"/>
>         <map:when test="">
>           <map:redirect-to session="true" uri="eval/home/form"/>
>         </map:when>
>         <map:when test="1">
>           <map:redirect-to session="true" uri="eval/first/first"/>
>         </map:when>
>         <map:when test="2">
>           <map:redirect-to session="true" uri="eval/second/second"/>
>         </map:when>
>         <map:otherwise>
>           <map:redirect-to session="true" uri="eval/home/form"/>
>         </map:otherwise>
>       </map:select>
> 
>       <map:match pattern="*/*">
>         <map:generate type="serverpages" src="logic/{1}/{2}.xsp"/>
>         <map:transform src="style/menupage.xsl">
>           <map:parameter name="toc-file" value="../content/toc.xml"/>
>           <map:parameter name="css-stylesheet" value="default.css"/>
>           <map:parameter name="base-url" value="/cocoon/eval"/>
>         </map:transform>
>         <map:serialize/>
>       </map:match>
>       ...
>     </map:pipeline>
> 
> I get the following compile error:
> 
> org.apache.cocoon.ProcessingException: Language Exception:
> org.apache.cocoon.components.language.LanguageException: Error
compiling
> sitemap_xmap:
> Line 440, column 6:  Undefined variable: param
> Line 441, column 6:  Undefined variable or class name: param
> Line 444, column 46:  Undefined variable: param
> Line 462, column 48:  Undefined variable: param
> Line 0, column 0:
> Note: D:\apps\Apache Tomcat
>
4.0\work\localhost\cocoon\cocoon-files\org\apache\cocoon\www\eval\sitema
> p_xmap.java uses or overrides a deprecated API.  Recompile with
> "-deprecation" for details.
> 4 errors, 1 warning
> 
>       at
>
org.apache.cocoon.components.language.generator.ProgramGeneratorImpl.cre
> ateResource(ProgramGeneratorImpl.java:285)
>       at
>
org.apache.cocoon.components.language.generator.ProgramGeneratorImpl.loa
> d(ProgramGeneratorImpl.java:196)
>       at org.apache.cocoon.sitemap.Handler.run(Handler.java:228)
>       at java.lang.Thread.run(Thread.java:484)
> 
> Any thoughts?
> 
> Thanks again.
> 
> Matthew


---------------------------------------------------------------------
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