You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cocoon.apache.org by Ganael LAPLANCHE <gl...@jouve.fr> on 2002/08/26 16:03:17 UTC

How to get URL parameters in an area ?

Hi !

I'd like to acces an URL variable in an <xsp:logic> area ???
I call my page with : http://..../foo.xml?bar=hello and would like to
get the value of bar into a string element to re-use it.

How would you do that ? Must be simple... but I'm a newbie... :)

Thank you,

Ganael.






---------------------------------------------------------------------
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:     <co...@xml.apache.org>
For additional commands, e-mail:   <co...@xml.apache.org>


Re: How to get URL parameters in an area ?

Posted by Ganael LAPLANCHE <gl...@jouve.fr>.
Ok, I submitted my form with a hidden value, it works very well :))
Thank you !!!

Gan.

On Mon, 2002-08-26 at 17:19, Michael Mangeng wrote:
> Hmmm
> 
> I´ve testet mixing POST and GET parameters and it works fine here....
> (tomcat 404, cocoon203, msie6x)
> Maybe your browser cannot mix the methods do this...
> Try submitting the GET parameter as a hidden param in the form..
> 
> <input type="hidden" name="bar" value="foo"/>
> 
> (or did  i misunderstand you?)
> 
> greetings
> mike
> ----- Original Message -----
> From: "Ganael LAPLANCHE" <gl...@jouve.fr>
> To: <co...@xml.apache.org>
> Sent: Monday, August 26, 2002 5:05 PM
> Subject: Re: How to get URL parameters in an <xsp:logic> area ?
> 
> 
> > I works fine with a hand-typed URL, but If the URL is requested
> > by a form (action="url?foo=bar"), it doesn't work... I can't acces to my
> > variable (even if it appears in the URL area of my navigator).
> > Do you have any idea ??? Many thanks...
> >
> > On Mon, 2002-08-26 at 16:11, Michael Mangeng wrote:
> > > Hi!
> > >
> > > You can use the <xsp-request:get-parameter name="bar"/> tag even inside
> the
> > > a <xsp:logic> tag.
> > >
> > > so you can do:
> > > <xsp:logic>
> > >     String myString = <xsp-request:get-parameter name="bar"/>;
> > > </xsp:logic>
> > >
> > > (xsp-request must be mapped to http://apache.org/xsp/request/2.0 )
> > > greetings
> > > mike
> > > ----- Original Message -----
> > > From: "Ganael LAPLANCHE" <gl...@jouve.fr>
> > > To: <co...@xml.apache.org>
> > > Sent: Monday, August 26, 2002 4:03 PM
> > > Subject: How to get URL parameters in an <xsp:logic> area ?
> > >
> > >
> > > > Hi !
> > > >
> > > > I'd like to acces an URL variable in an <xsp:logic> area ???
> > > > I call my page with : http://..../foo.xml?bar=hello and would like to
> > > > get the value of bar into a string element to re-use it.
> > > >
> > > > How would you do that ? Must be simple... but I'm a newbie... :)
> > > >
> > > > Thank you,
> > > >
> > > > Ganael.
> > > >
> > > >
> > > >
> > > >
> > > >
> > > >
> > > > ---------------------------------------------------------------------
> > > > 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:     <co...@xml.apache.org>
> > > > For additional commands, e-mail:   <co...@xml.apache.org>
> > > >
> > > >
> > >
> > >
> > > ---------------------------------------------------------------------
> > > 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:     <co...@xml.apache.org>
> > > For additional commands, e-mail:   <co...@xml.apache.org>
> > >
> > >
> >
> >
> >
> > ---------------------------------------------------------------------
> > 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:     <co...@xml.apache.org>
> > For additional commands, e-mail:   <co...@xml.apache.org>
> >
> >
> 
> 
> ---------------------------------------------------------------------
> 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:     <co...@xml.apache.org>
> For additional commands, e-mail:   <co...@xml.apache.org>
> 
> 



---------------------------------------------------------------------
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:     <co...@xml.apache.org>
For additional commands, e-mail:   <co...@xml.apache.org>


Re: How to get URL parameters in an area ?

Posted by Michael Mangeng <mi...@ideefix.net>.
Hmmm

I´ve testet mixing POST and GET parameters and it works fine here....
(tomcat 404, cocoon203, msie6x)
Maybe your browser cannot mix the methods do this...
Try submitting the GET parameter as a hidden param in the form..

<input type="hidden" name="bar" value="foo"/>

(or did  i misunderstand you?)

greetings
mike
----- Original Message -----
From: "Ganael LAPLANCHE" <gl...@jouve.fr>
To: <co...@xml.apache.org>
Sent: Monday, August 26, 2002 5:05 PM
Subject: Re: How to get URL parameters in an <xsp:logic> area ?


> I works fine with a hand-typed URL, but If the URL is requested
> by a form (action="url?foo=bar"), it doesn't work... I can't acces to my
> variable (even if it appears in the URL area of my navigator).
> Do you have any idea ??? Many thanks...
>
> On Mon, 2002-08-26 at 16:11, Michael Mangeng wrote:
> > Hi!
> >
> > You can use the <xsp-request:get-parameter name="bar"/> tag even inside
the
> > a <xsp:logic> tag.
> >
> > so you can do:
> > <xsp:logic>
> >     String myString = <xsp-request:get-parameter name="bar"/>;
> > </xsp:logic>
> >
> > (xsp-request must be mapped to http://apache.org/xsp/request/2.0 )
> > greetings
> > mike
> > ----- Original Message -----
> > From: "Ganael LAPLANCHE" <gl...@jouve.fr>
> > To: <co...@xml.apache.org>
> > Sent: Monday, August 26, 2002 4:03 PM
> > Subject: How to get URL parameters in an <xsp:logic> area ?
> >
> >
> > > Hi !
> > >
> > > I'd like to acces an URL variable in an <xsp:logic> area ???
> > > I call my page with : http://..../foo.xml?bar=hello and would like to
> > > get the value of bar into a string element to re-use it.
> > >
> > > How would you do that ? Must be simple... but I'm a newbie... :)
> > >
> > > Thank you,
> > >
> > > Ganael.
> > >
> > >
> > >
> > >
> > >
> > >
> > > ---------------------------------------------------------------------
> > > 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:     <co...@xml.apache.org>
> > > For additional commands, e-mail:   <co...@xml.apache.org>
> > >
> > >
> >
> >
> > ---------------------------------------------------------------------
> > 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:     <co...@xml.apache.org>
> > For additional commands, e-mail:   <co...@xml.apache.org>
> >
> >
>
>
>
> ---------------------------------------------------------------------
> 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:     <co...@xml.apache.org>
> For additional commands, e-mail:   <co...@xml.apache.org>
>
>


---------------------------------------------------------------------
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:     <co...@xml.apache.org>
For additional commands, e-mail:   <co...@xml.apache.org>


Re: How to get URL parameters in an area ?

Posted by Ganael LAPLANCHE <gl...@jouve.fr>.
I works fine with a hand-typed URL, but If the URL is requested
by a form (action="url?foo=bar"), it doesn't work... I can't acces to my
variable (even if it appears in the URL area of my navigator).
Do you have any idea ??? Many thanks...

On Mon, 2002-08-26 at 16:11, Michael Mangeng wrote:
> Hi!
> 
> You can use the <xsp-request:get-parameter name="bar"/> tag even inside the
> a <xsp:logic> tag.
> 
> so you can do:
> <xsp:logic>
>     String myString = <xsp-request:get-parameter name="bar"/>;
> </xsp:logic>
> 
> (xsp-request must be mapped to http://apache.org/xsp/request/2.0 )
> greetings
> mike
> ----- Original Message -----
> From: "Ganael LAPLANCHE" <gl...@jouve.fr>
> To: <co...@xml.apache.org>
> Sent: Monday, August 26, 2002 4:03 PM
> Subject: How to get URL parameters in an <xsp:logic> area ?
> 
> 
> > Hi !
> >
> > I'd like to acces an URL variable in an <xsp:logic> area ???
> > I call my page with : http://..../foo.xml?bar=hello and would like to
> > get the value of bar into a string element to re-use it.
> >
> > How would you do that ? Must be simple... but I'm a newbie... :)
> >
> > Thank you,
> >
> > Ganael.
> >
> >
> >
> >
> >
> >
> > ---------------------------------------------------------------------
> > 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:     <co...@xml.apache.org>
> > For additional commands, e-mail:   <co...@xml.apache.org>
> >
> >
> 
> 
> ---------------------------------------------------------------------
> 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:     <co...@xml.apache.org>
> For additional commands, e-mail:   <co...@xml.apache.org>
> 
> 



---------------------------------------------------------------------
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:     <co...@xml.apache.org>
For additional commands, e-mail:   <co...@xml.apache.org>


Re: How to get URL parameters in an area ?

Posted by Michael Mangeng <mi...@ideefix.net>.
Hi!

You can use the <xsp-request:get-parameter name="bar"/> tag even inside the
a <xsp:logic> tag.

so you can do:
<xsp:logic>
    String myString = <xsp-request:get-parameter name="bar"/>;
</xsp:logic>

(xsp-request must be mapped to http://apache.org/xsp/request/2.0 )
greetings
mike
----- Original Message -----
From: "Ganael LAPLANCHE" <gl...@jouve.fr>
To: <co...@xml.apache.org>
Sent: Monday, August 26, 2002 4:03 PM
Subject: How to get URL parameters in an <xsp:logic> area ?


> Hi !
>
> I'd like to acces an URL variable in an <xsp:logic> area ???
> I call my page with : http://..../foo.xml?bar=hello and would like to
> get the value of bar into a string element to re-use it.
>
> How would you do that ? Must be simple... but I'm a newbie... :)
>
> Thank you,
>
> Ganael.
>
>
>
>
>
>
> ---------------------------------------------------------------------
> 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:     <co...@xml.apache.org>
> For additional commands, e-mail:   <co...@xml.apache.org>
>
>


---------------------------------------------------------------------
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:     <co...@xml.apache.org>
For additional commands, e-mail:   <co...@xml.apache.org>