You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@wicket.apache.org by Goran <gn...@gmail.com> on 2007/07/10 12:04:02 UTC

PageParameters and bookmarkable page

I have a problem with passing request parameters to a Wicket page.

Bookmarkable page is defined in init method in WebApplication class like
this:
mountBookmarkablePage("/somepage", SomePage.class);

When I try to send parameters to that page from the form below:

<form action="http://someAddress/ApplicationName/app/somepage"
method="post">
	<input type="text" name="param1" id="param1"/><br />
	<input type="submit"/>
</form>

The SomePage doesn't get request parameter param1 from PageParameters
object.

But when I change action attribute in form to (add otherParm and any value):
http://someAddress/ApplicationName/app/somepage/otherParm/2
Then parm1 comes to the page also.

Why is that happening and how can I use
http://someAddress/ApplicationName/app/somepage
without the bogus otherParm parameter?

Thanks for the help :)


-- 
View this message in context: http://www.nabble.com/PageParameters-and-bookmarkable-page-tf4054941.html#a11518078
Sent from the Wicket - Dev mailing list archive at Nabble.com.


Re: PageParameters and bookmarkable page

Posted by Igor Vaynberg <ig...@gmail.com>.
On 7/10/07, Johan Compagner <jc...@gmail.com> wrote:
>
> this should work, do you have a quickstart that demonstrates this?


ive noticed a few messages about this, but havent had time to look yet. it
looks like we do not properly merge query strings parameters into other
coding strategies. for example, the default startegy expects
/param1/value1/param2/value2, but if you do /param1/value1?param2=value2 the
querystring wont get merged. it should imho. to give you a bit of a clue
when you look into it

-igor





On 7/10/07, Goran <gn...@gmail.com> wrote:
> >
> >
> > I have a problem with passing request parameters to a Wicket page.
> >
> > Bookmarkable page is defined in init method in WebApplication class like
> > this:
> > mountBookmarkablePage("/somepage", SomePage.class);
> >
> > When I try to send parameters to that page from the form below:
> >
> > <form action="http://someAddress/ApplicationName/app/somepage"
> > method="post">
> >         <input type="text" name="param1" id="param1"/><br />
> >         <input type="submit"/>
> > </form>
> >
> > The SomePage doesn't get request parameter param1 from PageParameters
> > object.
> >
> > But when I change action attribute in form to (add otherParm and any
> > value):
> > http://someAddress/ApplicationName/app/somepage/otherParm/2
> > Then parm1 comes to the page also.
> >
> > Why is that happening and how can I use
> > http://someAddress/ApplicationName/app/somepage
> > without the bogus otherParm parameter?
> >
> > Thanks for the help :)
> >
> >
> > --
> > View this message in context:
> >
> http://www.nabble.com/PageParameters-and-bookmarkable-page-tf4054941.html#a11518078
> > Sent from the Wicket - Dev mailing list archive at Nabble.com.
> >
> >
>

Re: PageParameters and bookmarkable page

Posted by Johan Compagner <jc...@gmail.com>.
this should work, do you have a quickstart that demonstrates this?



On 7/10/07, Goran <gn...@gmail.com> wrote:
>
>
> I have a problem with passing request parameters to a Wicket page.
>
> Bookmarkable page is defined in init method in WebApplication class like
> this:
> mountBookmarkablePage("/somepage", SomePage.class);
>
> When I try to send parameters to that page from the form below:
>
> <form action="http://someAddress/ApplicationName/app/somepage"
> method="post">
>         <input type="text" name="param1" id="param1"/><br />
>         <input type="submit"/>
> </form>
>
> The SomePage doesn't get request parameter param1 from PageParameters
> object.
>
> But when I change action attribute in form to (add otherParm and any
> value):
> http://someAddress/ApplicationName/app/somepage/otherParm/2
> Then parm1 comes to the page also.
>
> Why is that happening and how can I use
> http://someAddress/ApplicationName/app/somepage
> without the bogus otherParm parameter?
>
> Thanks for the help :)
>
>
> --
> View this message in context:
> http://www.nabble.com/PageParameters-and-bookmarkable-page-tf4054941.html#a11518078
> Sent from the Wicket - Dev mailing list archive at Nabble.com.
>
>