You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cocoon.apache.org by Mansour Al Akeel <ma...@gmail.com> on 2009/06/01 20:45:26 UTC
Re: Regexp matcher with digits
Can someone kindly answer this question and give an example about how to
use regex and retrieve the matches. I am stuck with a project that's
writen in Cocoon and I need this to continue.
On Sun May 31,2009 01:54 am, Mansour Al Akeel wrote:
> Ok, let's clarify this and put it in different words. I am able to match
> on the digits part but not able to obtain this digits
>
> <map:match type="regexp" pattern="\.*/\d$">
> ......
> .....
> <map:parameter name="href" value="{1}"/>
> <map:parameter name="depth" value="{2}"/>
>
> The variable {1} is matching and I can obtain as expected, but {2} is
> not.
>
>
> Can someone please share the knowledge and direct me to resolve this ?
>
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org
Re: Regexp matcher with digits
Posted by Mansour Al Akeel <ma...@gmail.com>.
Peter:
I didn't try it, but it's working. I need to refine it a bit, but that's
what I wanted. Thank you very much.
On Mon Jun 01,2009 01:11 pm, Binkley, Peter wrote:
> Did you try "(\.*)/(\d)$"?
>
> Peter
>
>
>
> > -----Original Message-----
> > From: Mansour Al Akeel [mailto:mansour.alakeel@gmail.com]
> > Sent: Monday, June 01, 2009 12:45 PM
> > To: users@cocoon.apache.org
> > Subject: Re: Regexp matcher with digits
> >
> > Can someone kindly answer this question and give an example
> > about how to use regex and retrieve the matches. I am stuck
> > with a project that's writen in Cocoon and I need this to continue.
> >
> >
> > On Sun May 31,2009 01:54 am, Mansour Al Akeel wrote:
> > > Ok, let's clarify this and put it in different words. I am able to
> > > match on the digits part but not able to obtain this digits
> > >
> > > <map:match type="regexp" pattern="\.*/\d$">
> > > ......
> > > .....
> > > <map:parameter name="href" value="{1}"/>
> > > <map:parameter name="depth" value="{2}"/>
> > >
> > > The variable {1} is matching and I can obtain as expected,
> > but {2} is
> > > not.
> > >
> > >
> > > Can someone please share the knowledge and direct me to
> > resolve this ?
> > >
> > >
> > >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
> > For additional commands, e-mail: users-help@cocoon.apache.org
> >
> >
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
> For additional commands, e-mail: users-help@cocoon.apache.org
>
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org
RE: Regexp matcher with digits
Posted by "Binkley, Peter" <Pe...@ualberta.ca>.
Did you try "(\.*)/(\d)$"?
Peter
> -----Original Message-----
> From: Mansour Al Akeel [mailto:mansour.alakeel@gmail.com]
> Sent: Monday, June 01, 2009 12:45 PM
> To: users@cocoon.apache.org
> Subject: Re: Regexp matcher with digits
>
> Can someone kindly answer this question and give an example
> about how to use regex and retrieve the matches. I am stuck
> with a project that's writen in Cocoon and I need this to continue.
>
>
> On Sun May 31,2009 01:54 am, Mansour Al Akeel wrote:
> > Ok, let's clarify this and put it in different words. I am able to
> > match on the digits part but not able to obtain this digits
> >
> > <map:match type="regexp" pattern="\.*/\d$">
> > ......
> > .....
> > <map:parameter name="href" value="{1}"/>
> > <map:parameter name="depth" value="{2}"/>
> >
> > The variable {1} is matching and I can obtain as expected,
> but {2} is
> > not.
> >
> >
> > Can someone please share the knowledge and direct me to
> resolve this ?
> >
> >
> >
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
> For additional commands, e-mail: users-help@cocoon.apache.org
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org