> From: Pascal Davoust [mailto:[EMAIL PROTECTED]]
> 
> Mmh, I probably missed something here... I tried what you proposed,
but I
> get a compilation error. Here's what I did at first, which works
correctly:
> 
> <map:pipeline>
>   <map:match pattern="account">
>     <!-- Makes sure that authentication has been successful -->
>     <map:act type="session-validator">
>       <map:parameter name="descriptor"
>            value="file://config/session-params.xml"/>
>       <map:parameter name="validate" value="user/login"/>
> 
>       <!-- The protected content for that match -->
>     </map:act>
>   </map:match>
> </map:pipeline>
> 
> (login is in another pipeline... does it matter?)

(no, but order might be of importance: pipelines are executed one by
one)

 
> And then I tried to reverse the pattern, like this:

Congratulations, you found a bug :)
Remove <map:parameter>:

> <map:pipeline>
>   <!-- Makes sure that authentication has been successful -->
>   <map:act type="session-validator">
> 
>     <map:match pattern="account">
>       <!-- The protected content for that match -->
>     </map:match>
>   </map:act>
> </map:pipeline>
> 
> And I get an error, which is :
> Error compiling sitemap_xmap: Line 901, column 6: Undefined variable:
param

And it will compile.

 
> I had a look to the source code, it's obviously missing the variable
> declaration. Did I forget something here?
> 
> By the way, I found that the "context://..." specifier as a parameter
value
> for the action descriptor doesn't work

Don't remember action sources... It just might be they do not use
resolver to get descriptor.


> (did I correctly understand that this
> sub-protocol is related to the sitemap?),

Any (sub) protocol can be used throughout the system if using resolver.

PS: Grab CVS version of sitemap.xsl - it has the bug fixed.

Regards,
Vadim

> whereas "file://...." does the
> trick (I want to specify a path relative to the sitemap its written
into).
> 
> Thanks,
> 
>                       Pascal.


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

Reply via email to