Hi Sergio,

thanks for your contribution! It looks really interesting.
If noone else is looking at it in the next days, I would ask 
you to add these to bugzilla as an enhancement so that it
doesn't get lost.

Carsten

> -----Original Message-----
> From: Sergio Carvalho [mailto:[EMAIL PROTECTED]]
> Sent: Sunday, October 14, 2001 11:58 PM
> To: [EMAIL PROTECTED]
> Subject: [donation] SectionCutter action
> 
> 
> Hi,
> 
> I'm sorry for the delay sending the section cutter action I 
> talked about in a
> thread some days ago. I had plans for implementing regexp 
> matching on the action
> before donating it to the Cocoon project, but too many 
> last-minute tasks pop up
> too often :-( I'll try to pick this up next weekend.
> 
> The action is used like this:
> 1) Declare the action in the map:actions element of the sitemap. 
> Define the
> different site sections, and the variables there:
>      <map:action name="cut-section" 
>                  src="org.apache.cocoon.acting.SectionCutterAction">
>         <section pattern="jogos">
>           <set-var name="section" value="jogos" />
>           <set-var name="title" value="Jogos" />
>         </section>
>         <section pattern="forums/read/chat/quadro/">
>           <set-var name="section" value="chat" />
>           <set-var name="title" value="Chat" />
>           <set-var name="dart" value="tagarela.portugalmail.pt" />
>         </section>
>       </map:action>
> 
> 2) Use the action on the sitemap, just like all other actions:
>      <map:match pattern="**">
>        <map:act type="cut-section">
>        ...
> 
> The variables defined with set-var on the section definition will 
> be available
> in the sitemap as {section}, {title}, {dart} for the example above.
> 
> Currently, the pattern matches against the beggining of the URI, with no
> wildcards. I plan (need) to have it match regular expressions.
> 
> Cheers,
> 
> --
> Sergio Carvalho
> ---------------
> [EMAIL PROTECTED]
> 
> If at first you don't succeed, skydiving is not for you
> 

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

Reply via email to