Thanks Adam. I appreciate it. I changed it accordingly, and it works.

So conceptually, if we nest blocks (of action or resource calls or anything nestable?) in a pattern matcher, all the references to the pattern should be resolved with relative path from the actual level to the pattern. Ie if I nest another action, and try to use matched pattern, I shoud refer to it as {../../1}. Is that a correct interpretation?

Does this apply to XML in general or just the cocoon sitemap?

Thanks again.

Kind regards,
Bhaskar

Adam Ratcliffe wrote:

Hi Bhaskar

Because the variable that you're trying to access within your action belongs
to the enclosing
matcher and not the action itself you need to reference it as {../1}.

HTH
Adam

-----Original Message-----
From: Bhaskar Rathod [mailto:[EMAIL PROTECTED]
Sent: Thursday, 13 January 2005 12:00 p.m.
To: [email protected]
Subject: Auth-Protect and wildcard matcher


Hello,

I am using auth framework successfully, but recently I am having trouble
with wildcard pattern matchers and auth-protect action.

My pipeline matcher is as follows:

    <map:match pattern="*.xml">
      <map:act type="auth-protect">
           <map:parameter name="handler" value="LoginHandler"/>

        <map:read mime-type="text/html" src="submissions/{1}.xml"/>
        <map:serialize type="text"/>
      </map:act>

      <map:redirect-to uri="login"/>
    </map:match>

However, the src received by map:read (the parameter {1}) is empty. If I
remove authentication altogether, things work fine.
ie
    <map:match pattern="*.xml">
      <map:read mime-type="text/html" src="submissions/{1}.xml"/>
      <map:serialize type="text"/>
    </map:match>

Then the parameter  {1} resolves correctly.

Any Ideas appreciated.

Kind regards,

Bhaskar


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




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





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



Reply via email to