You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@wicket.apache.org by "V. Jenks" <za...@gmail.com> on 2007/08/31 22:14:33 UTC

BookmarkablePage URL

I'm sure this has been asked 1000x but I'm unable to find the answer...and
don't have enough time left to keep digging.

I simply want to call a bookmarkable page and pass it a parameter value...

I got this far but my guesses have so far been wrong:

?wicket:bookmarkablePage=:com.myapp.BookmarkedPage&catid=1

I get this error:

"ERROR [RequestCycle] Can't instantiate page using constructor public
com.myapp.BookmarkedPage(wicket.PageParameters) and argument catid = "1""

It seems strange that I'm unable to quickly find an example of the URL
format.  I've been away from Wicket for a few months and when I tried to use
1.2.6, I had a bunch of failures on code that currently works in 1.2.4, so
I've stuck w/ that until I have time to figure out what's changed.

Thanks!
-- 
View this message in context: http://www.nabble.com/BookmarkablePage-URL-tf4362196.html#a12433271
Sent from the Wicket - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org


Re: BookmarkablePage URL

Posted by "V. Jenks" <za...@gmail.com>.
TEST - I tried to reply to this again, about an hour ago...but the message
still hasn't appeared.  Should I just post it again?


V. Jenks wrote:
> 
> I'm sure this has been asked 1000x but I'm unable to find the answer...and
> don't have enough time left to keep digging.
> 
> I simply want to call a bookmarkable page and pass it a parameter value...
> 
> I got this far but my guesses have so far been wrong:
> 
> ?wicket:bookmarkablePage=:com.myapp.BookmarkedPage&catid=1
> 
> I get this error:
> 
> "ERROR [RequestCycle] Can't instantiate page using constructor public
> com.myapp.BookmarkedPage(wicket.PageParameters) and argument catid = "1""
> 
> It seems strange that I'm unable to quickly find an example of the URL
> format.  I've been away from Wicket for a few months and when I tried to
> use 1.2.6, I had a bunch of failures on code that currently works in
> 1.2.4, so I've stuck w/ that until I have time to figure out what's
> changed.
> 
> Thanks!
> 

-- 
View this message in context: http://www.nabble.com/BookmarkablePage-URL-tf4362196.html#a12604056
Sent from the Wicket - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org


Re: BookmarkablePage URL

Posted by Igor Vaynberg <ig...@gmail.com>.
you dont build urls like that, you mount pages - then you know what the url
is.

what is the full stack trace?

-igor


On 8/31/07, V. Jenks <za...@gmail.com> wrote:
>
>
> I'm sure this has been asked 1000x but I'm unable to find the answer...and
> don't have enough time left to keep digging.
>
> I simply want to call a bookmarkable page and pass it a parameter value...
>
> I got this far but my guesses have so far been wrong:
>
> ?wicket:bookmarkablePage=:com.myapp.BookmarkedPage&catid=1
>
> I get this error:
>
> "ERROR [RequestCycle] Can't instantiate page using constructor public
> com.myapp.BookmarkedPage(wicket.PageParameters) and argument catid = "1""
>
> It seems strange that I'm unable to quickly find an example of the URL
> format.  I've been away from Wicket for a few months and when I tried to
> use
> 1.2.6, I had a bunch of failures on code that currently works in 1.2.4, so
> I've stuck w/ that until I have time to figure out what's changed.
>
> Thanks!
> --
> View this message in context:
> http://www.nabble.com/BookmarkablePage-URL-tf4362196.html#a12433271
> Sent from the Wicket - User mailing list archive at Nabble.com.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
> For additional commands, e-mail: users-help@wicket.apache.org
>
>

Re: BookmarkablePage URL

Posted by Eelco Hillenius <ee...@gmail.com>.
On 9/11/07, V. Jenks <za...@gmail.com> wrote:
>
> Can anyone help out w/ this?  I'm stumped.  The images are somehow being
> passes as parameters?  It isn't all of the images on the page because some
> of them show up...and they're all in the same folder.  This makes no sense
> to me.

How do you include those images? Did you check you have the same
problem with the latests 1.2.x version as well? Do you have some
example code for us please?

Eelco

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org


Re: BookmarkablePage URL

Posted by "V. Jenks" <za...@gmail.com>.
Can anyone help out w/ this?  I'm stumped.  The images are somehow being
passes as parameters?  It isn't all of the images on the page because some
of them show up...and they're all in the same folder.  This makes no sense
to me.

I could wrap this thing up and put it away (thanks to everyone's help here)
- if I could get past this issue.

Thanks again!


V. Jenks wrote:
> 
> Thanks guys, this has all been really helpful.
> 
> I'm having some bizarre results, even though the page is loading now. 
> Some of the images aren't loading and I'm getting exceptions that appear
> to tell me that the images are being passed as the parameter values, as
> well?
> 
> I mounted the url like so (in app's init() method):
> 
> mountBookmarkablePage("/category", CatalogCategory.class);
> 
> And I called up the url, w/ parameter, like so:
> 
> http://localhost:8080/MyApp/products/category/catid/1
> 
> I see the data I should be seeing, save for a few of the images not
> loading.
> 
> Here's my stack trace:
> 
> ****************************************************************
> 12:54:41,893 ERROR [RequestCycle] Can't instantiate page using constructor
> public com.myapp.CatalogCategory(wicket.PageParameters) and argument
> images = "background.jpg" catid = "assets"
> wicket.WicketRuntimeException: Can't instantiate page using constructor
> public com.myapp.CatalogCategory(wicket.PageParameters) and argument
> images = "background.jpg" catid = "assets"
> 	at wicket.session.DefaultPageFactory.newPage(DefaultPageFactory.java:175)
> 	at wicket.session.DefaultPageFactory.newPage(DefaultPageFactory.java:96)
> 	at
> wicket.request.target.component.BookmarkablePageRequestTarget.newPage(BookmarkablePageRequestTarget.java:271)
> 	at
> wicket.request.target.component.BookmarkablePageRequestTarget.getPage(BookmarkablePageRequestTarget.java:286)
> 	at
> wicket.request.target.component.BookmarkablePageRequestTarget.processEvents(BookmarkablePageRequestTarget.java:205)
> 	at
> wicket.request.compound.DefaultEventProcessorStrategy.processEvents(DefaultEventProcessorStrategy.java:65)
> 	at
> wicket.request.compound.AbstractCompoundRequestCycleProcessor.processEvents(AbstractCompoundRequestCycleProcessor.java:57)
> 	at wicket.RequestCycle.doProcessEventsAndRespond(RequestCycle.java:896)
> 	at wicket.RequestCycle.processEventsAndRespond(RequestCycle.java:929)
> 	at wicket.RequestCycle.step(RequestCycle.java:1010)
> 	at wicket.RequestCycle.steps(RequestCycle.java:1084)
> 	at wicket.RequestCycle.request(RequestCycle.java:454)
> 	at wicket.protocol.http.WicketServlet.doGet(WicketServlet.java:219)
> 	at javax.servlet.http.HttpServlet.service(HttpServlet.java:697)
> 	at javax.servlet.http.HttpServlet.service(HttpServlet.java:810)
> 	at
> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
> 	at
> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
> 	at
> org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
> 	at
> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
> 	at
> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
> 	at
> org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
> 	at
> org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
> 	at
> org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:175)
> 	at
> org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:74)
> 	at
> org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
> 	at
> org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
> 	at
> org.jboss.web.tomcat.tc5.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:156)
> 	at
> org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
> 	at
> org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
> 	at
> org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)
> 	at
> org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:664)
> 	at
> org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
> 	at
> org.apache.tomcat.util.net.MasterSlaveWorkerThread.run(MasterSlaveWorkerThread.java:112)
> 	at java.lang.Thread.run(Thread.java:619)
> Caused by: java.lang.reflect.InvocationTargetException
> 	at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
> 	at
> sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
> 	at
> sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
> 	at java.lang.reflect.Constructor.newInstance(Constructor.java:513)
> 	at wicket.session.DefaultPageFactory.newPage(DefaultPageFactory.java:154)
> 	... 33 more
> Caused by: java.lang.NumberFormatException: For input string: "assets"
> 	at
> java.lang.NumberFormatException.forInputString(NumberFormatException.java:48)
> 	at java.lang.Integer.parseInt(Integer.java:447)
> 	at java.lang.Integer.valueOf(Integer.java:553)
> 	at com.myapp.CatalogCategory.<init>(CatalogCategory.java:31)
> 	... 38 more
> ****************************************************************
> 
> 
> V. Jenks wrote:
>> 
>> I'm sure this has been asked 1000x but I'm unable to find the
>> answer...and don't have enough time left to keep digging.
>> 
>> I simply want to call a bookmarkable page and pass it a parameter
>> value...
>> 
>> I got this far but my guesses have so far been wrong:
>> 
>> ?wicket:bookmarkablePage=:com.myapp.BookmarkedPage&catid=1
>> 
>> I get this error:
>> 
>> "ERROR [RequestCycle] Can't instantiate page using constructor public
>> com.myapp.BookmarkedPage(wicket.PageParameters) and argument catid = "1""
>> 
>> It seems strange that I'm unable to quickly find an example of the URL
>> format.  I've been away from Wicket for a few months and when I tried to
>> use 1.2.6, I had a bunch of failures on code that currently works in
>> 1.2.4, so I've stuck w/ that until I have time to figure out what's
>> changed.
>> 
>> Thanks!
>> 
> 
> 

-- 
View this message in context: http://www.nabble.com/BookmarkablePage-URL-tf4362196.html#a12616347
Sent from the Wicket - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org


Re: BookmarkablePage URL

Posted by "V. Jenks" <za...@gmail.com>.
Thanks guys, this has all been really helpful.

I'm having some bizarre results, even though the page is loading now.  Some
of the images aren't loading and I'm getting exceptions that appear to tell
me that the images are being passed as the parameter values, as well?

I mounted the url like so (in app's init() method):

mountBookmarkablePage("/category", CatalogCategory.class);

And I called up the url, w/ parameter, like so:

http://localhost:8080/MyApp/products/category/catid/1

I see the data I should be seeing, save for a few of the images not loading.

Here's my stack trace:

****************************************************************
12:54:41,893 ERROR [RequestCycle] Can't instantiate page using constructor
public com.myapp.CatalogCategory(wicket.PageParameters) and argument images
= "background.jpg" catid = "assets"
wicket.WicketRuntimeException: Can't instantiate page using constructor
public com.myapp.CatalogCategory(wicket.PageParameters) and argument images
= "background.jpg" catid = "assets"
	at wicket.session.DefaultPageFactory.newPage(DefaultPageFactory.java:175)
	at wicket.session.DefaultPageFactory.newPage(DefaultPageFactory.java:96)
	at
wicket.request.target.component.BookmarkablePageRequestTarget.newPage(BookmarkablePageRequestTarget.java:271)
	at
wicket.request.target.component.BookmarkablePageRequestTarget.getPage(BookmarkablePageRequestTarget.java:286)
	at
wicket.request.target.component.BookmarkablePageRequestTarget.processEvents(BookmarkablePageRequestTarget.java:205)
	at
wicket.request.compound.DefaultEventProcessorStrategy.processEvents(DefaultEventProcessorStrategy.java:65)
	at
wicket.request.compound.AbstractCompoundRequestCycleProcessor.processEvents(AbstractCompoundRequestCycleProcessor.java:57)
	at wicket.RequestCycle.doProcessEventsAndRespond(RequestCycle.java:896)
	at wicket.RequestCycle.processEventsAndRespond(RequestCycle.java:929)
	at wicket.RequestCycle.step(RequestCycle.java:1010)
	at wicket.RequestCycle.steps(RequestCycle.java:1084)
	at wicket.RequestCycle.request(RequestCycle.java:454)
	at wicket.protocol.http.WicketServlet.doGet(WicketServlet.java:219)
	at javax.servlet.http.HttpServlet.service(HttpServlet.java:697)
	at javax.servlet.http.HttpServlet.service(HttpServlet.java:810)
	at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
	at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
	at
org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
	at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
	at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
	at
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
	at
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
	at
org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:175)
	at
org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:74)
	at
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
	at
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
	at
org.jboss.web.tomcat.tc5.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:156)
	at
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
	at
org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
	at
org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)
	at
org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:664)
	at
org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
	at
org.apache.tomcat.util.net.MasterSlaveWorkerThread.run(MasterSlaveWorkerThread.java:112)
	at java.lang.Thread.run(Thread.java:619)
Caused by: java.lang.reflect.InvocationTargetException
	at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
	at
sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
	at
sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
	at java.lang.reflect.Constructor.newInstance(Constructor.java:513)
	at wicket.session.DefaultPageFactory.newPage(DefaultPageFactory.java:154)
	... 33 more
Caused by: java.lang.NumberFormatException: For input string: "assets"
	at
java.lang.NumberFormatException.forInputString(NumberFormatException.java:48)
	at java.lang.Integer.parseInt(Integer.java:447)
	at java.lang.Integer.valueOf(Integer.java:553)
	at com.myapp.CatalogCategory.<init>(CatalogCategory.java:31)
	... 38 more
****************************************************************


V. Jenks wrote:
> 
> I'm sure this has been asked 1000x but I'm unable to find the answer...and
> don't have enough time left to keep digging.
> 
> I simply want to call a bookmarkable page and pass it a parameter value...
> 
> I got this far but my guesses have so far been wrong:
> 
> ?wicket:bookmarkablePage=:com.myapp.BookmarkedPage&catid=1
> 
> I get this error:
> 
> "ERROR [RequestCycle] Can't instantiate page using constructor public
> com.myapp.BookmarkedPage(wicket.PageParameters) and argument catid = "1""
> 
> It seems strange that I'm unable to quickly find an example of the URL
> format.  I've been away from Wicket for a few months and when I tried to
> use 1.2.6, I had a bunch of failures on code that currently works in
> 1.2.4, so I've stuck w/ that until I have time to figure out what's
> changed.
> 
> Thanks!
> 

-- 
View this message in context: http://www.nabble.com/BookmarkablePage-URL-tf4362196.html#a12602107
Sent from the Wicket - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org


Re: BookmarkablePage URL

Posted by Eelco Hillenius <ee...@gmail.com>.
> I guess I'm completely confused.  I'm pretty sure I've done it this way
> before and it worked fine...but it's been a while.  I've never mounted a URL
> before, I'm not familiar w/ it.

It should work without. What we're saying is make it easier for
yourself and use mounting.

Eelco

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org


Re: BookmarkablePage URL

Posted by Korbinian Bachl <ko...@whiskyworld.de>.

V. Jenks schrieb:
> Where is this mounting done?  

its done in the init() of your WebApplication class e.g:

     /**
      * @see org.apache.wicket.examples.WicketExampleApplication#init()
      */
     protected void init() {
         mount(new HybridUrlCodingStrategy("/index", Index.class));
    }



>What about parameter values?

if you have a page, then make sure your constructor has a PageParameters 
params there, and you can access then your param catid by doing 
params.getString("catid") (or getInt("catid") bit then you will get an 
error if not int).

some more info is here: http://www.javalobby.org/java/forums/t68753.html

Regards,

Korbinian

> 
> What I've got is really quite simple.  I have a static HTML page on an old
> web site that needs to link to a wicket page.  The wicket page pulls up a
> list of products based on the category provided in the querystring parameter
> in the URL.
> 
> ?catid=1
> ?catid=2
> etc....
> 
> It seems like a simple problem but I can't find a good example...
> 
> 
> Matej Knopp-2 wrote:
>> it's simple :)
>>
>> application.mountBookmarkablePage("/home/page", HomePage.class);
>>
>> and the url can look like
>> http://server.com/context/home/page/cat/4
>>
>> -Matej
>>
>> On 8/31/07, V. Jenks <za...@gmail.com> wrote:
>>>
>>> I guess I'm completely confused.  I'm pretty sure I've done it this way
>>> before and it worked fine...but it's been a while.  I've never mounted a
>>> URL
>>> before, I'm not familiar w/ it.
>>>
>>> I've been going through the Reference Library on the wiki and I can't
>>> find
>>> an example of how to do this and what the URL actually looks like...can
>>> you
>>> maybe point me to some instructions?
>>>
>>> Thanks!
>>>
>>>
>>> Eelco Hillenius wrote:
>>>> On 8/31/07, V. Jenks <za...@gmail.com> wrote:
>>>>> I'm sure this has been asked 1000x but I'm unable to find the
>>>>> answer...and
>>>>> don't have enough time left to keep digging.
>>>>>
>>>>> I simply want to call a bookmarkable page and pass it a parameter
>>>>> value...
>>>>>
>>>>> I got this far but my guesses have so far been wrong:
>>>>>
>>>>> ?wicket:bookmarkablePage=:com.myapp.BookmarkedPage&catid=1
>>>>>
>>>>> I get this error:
>>>>>
>>>>> "ERROR [RequestCycle] Can't instantiate page using constructor public
>>>>> com.myapp.BookmarkedPage(wicket.PageParameters) and argument catid =
>>> "1""
>>>> That looks like there is a problem constructing your page, not so much
>>>> the format. Could you look further in your stack trace? Does
>>>> BookmarkedPage has a public default constructor or one with just a
>>>> page parameters argument?
>>>>
>>>> Btw, if you mount your pages (per package or individually), it is a
>>>> bit easier to test.
>>>>
>>>> Eelco
>>>>
>>>> ---------------------------------------------------------------------
>>>> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
>>>> For additional commands, e-mail: users-help@wicket.apache.org
>>>>
>>>>
>>>>
>>> --
>>> View this message in context:
>>> http://www.nabble.com/BookmarkablePage-URL-tf4362196.html#a12434374
>>> Sent from the Wicket - User mailing list archive at Nabble.com.
>>>
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
>>> For additional commands, e-mail: users-help@wicket.apache.org
>>>
>>>
>>
> 

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org


Re: BookmarkablePage URL

Posted by Eelco Hillenius <ee...@gmail.com>.
> Where is this mounting done?  What about parameter values?

You would typically do this in your application class, and parameters
are converted to part of the path or something else depending on how
you configure things. See for a simple example "niceurl" of
wicket-examples.

> What I've got is really quite simple.  I have a static HTML page on an old
> web site that needs to link to a wicket page.  The wicket page pulls up a
> list of products based on the category provided in the querystring parameter
> in the URL.
>
> ?catid=1
> ?catid=2
> etc....

/mysite/mymount/catid/1

Eelco

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org


Re: BookmarkablePage URL

Posted by Eelco Hillenius <ee...@gmail.com>.
> Where is this mounting done?  What about parameter values?

You would typically do this in your application class, and parameters
are converted to part of the path or something else depending on how
you configure things. See for a simple example "niceurl" of
wicket-examples.

> What I've got is really quite simple.  I have a static HTML page on an old
> web site that needs to link to a wicket page.  The wicket page pulls up a
> list of products based on the category provided in the querystring parameter
> in the URL.
>
> ?catid=1
> ?catid=2
> etc....

/mysite/mymount/catid/1

Eelco

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org


Re: BookmarkablePage URL

Posted by Eelco Hillenius <ee...@gmail.com>.
> Where is this mounting done?  What about parameter values?

You would typically do this in your application class, and parameters
are converted to part of the path or something else depending on how
you configure things. See for a simple example "niceurl" of
wicket-examples.

> What I've got is really quite simple.  I have a static HTML page on an old
> web site that needs to link to a wicket page.  The wicket page pulls up a
> list of products based on the category provided in the querystring parameter
> in the URL.
>
> ?catid=1
> ?catid=2
> etc....

/mysite/mymount/catid/1

Eelco

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org


Re: BookmarkablePage URL

Posted by "V. Jenks" <za...@gmail.com>.
Where is this mounting done?  What about parameter values?

What I've got is really quite simple.  I have a static HTML page on an old
web site that needs to link to a wicket page.  The wicket page pulls up a
list of products based on the category provided in the querystring parameter
in the URL.

?catid=1
?catid=2
etc....

It seems like a simple problem but I can't find a good example...


Matej Knopp-2 wrote:
> 
> it's simple :)
> 
> application.mountBookmarkablePage("/home/page", HomePage.class);
> 
> and the url can look like
> http://server.com/context/home/page/cat/4
> 
> -Matej
> 
> On 8/31/07, V. Jenks <za...@gmail.com> wrote:
>>
>>
>> I guess I'm completely confused.  I'm pretty sure I've done it this way
>> before and it worked fine...but it's been a while.  I've never mounted a
>> URL
>> before, I'm not familiar w/ it.
>>
>> I've been going through the Reference Library on the wiki and I can't
>> find
>> an example of how to do this and what the URL actually looks like...can
>> you
>> maybe point me to some instructions?
>>
>> Thanks!
>>
>>
>> Eelco Hillenius wrote:
>> >
>> > On 8/31/07, V. Jenks <za...@gmail.com> wrote:
>> >>
>> >> I'm sure this has been asked 1000x but I'm unable to find the
>> >> answer...and
>> >> don't have enough time left to keep digging.
>> >>
>> >> I simply want to call a bookmarkable page and pass it a parameter
>> >> value...
>> >>
>> >> I got this far but my guesses have so far been wrong:
>> >>
>> >> ?wicket:bookmarkablePage=:com.myapp.BookmarkedPage&catid=1
>> >>
>> >> I get this error:
>> >>
>> >> "ERROR [RequestCycle] Can't instantiate page using constructor public
>> >> com.myapp.BookmarkedPage(wicket.PageParameters) and argument catid =
>> "1""
>> >
>> > That looks like there is a problem constructing your page, not so much
>> > the format. Could you look further in your stack trace? Does
>> > BookmarkedPage has a public default constructor or one with just a
>> > page parameters argument?
>> >
>> > Btw, if you mount your pages (per package or individually), it is a
>> > bit easier to test.
>> >
>> > Eelco
>> >
>> > ---------------------------------------------------------------------
>> > To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
>> > For additional commands, e-mail: users-help@wicket.apache.org
>> >
>> >
>> >
>>
>> --
>> View this message in context:
>> http://www.nabble.com/BookmarkablePage-URL-tf4362196.html#a12434374
>> Sent from the Wicket - User mailing list archive at Nabble.com.
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
>> For additional commands, e-mail: users-help@wicket.apache.org
>>
>>
> 
> 

-- 
View this message in context: http://www.nabble.com/BookmarkablePage-URL-tf4362196.html#a12598227
Sent from the Wicket - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org


Re: BookmarkablePage URL

Posted by Matej Knopp <ma...@gmail.com>.
it's simple :)

application.mountBookmarkablePage("/home/page", HomePage.class);

and the url can look like
http://server.com/context/home/page/cat/4

-Matej

On 8/31/07, V. Jenks <za...@gmail.com> wrote:
>
>
> I guess I'm completely confused.  I'm pretty sure I've done it this way
> before and it worked fine...but it's been a while.  I've never mounted a
> URL
> before, I'm not familiar w/ it.
>
> I've been going through the Reference Library on the wiki and I can't find
> an example of how to do this and what the URL actually looks like...can
> you
> maybe point me to some instructions?
>
> Thanks!
>
>
> Eelco Hillenius wrote:
> >
> > On 8/31/07, V. Jenks <za...@gmail.com> wrote:
> >>
> >> I'm sure this has been asked 1000x but I'm unable to find the
> >> answer...and
> >> don't have enough time left to keep digging.
> >>
> >> I simply want to call a bookmarkable page and pass it a parameter
> >> value...
> >>
> >> I got this far but my guesses have so far been wrong:
> >>
> >> ?wicket:bookmarkablePage=:com.myapp.BookmarkedPage&catid=1
> >>
> >> I get this error:
> >>
> >> "ERROR [RequestCycle] Can't instantiate page using constructor public
> >> com.myapp.BookmarkedPage(wicket.PageParameters) and argument catid =
> "1""
> >
> > That looks like there is a problem constructing your page, not so much
> > the format. Could you look further in your stack trace? Does
> > BookmarkedPage has a public default constructor or one with just a
> > page parameters argument?
> >
> > Btw, if you mount your pages (per package or individually), it is a
> > bit easier to test.
> >
> > Eelco
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
> > For additional commands, e-mail: users-help@wicket.apache.org
> >
> >
> >
>
> --
> View this message in context:
> http://www.nabble.com/BookmarkablePage-URL-tf4362196.html#a12434374
> Sent from the Wicket - User mailing list archive at Nabble.com.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
> For additional commands, e-mail: users-help@wicket.apache.org
>
>

Re: BookmarkablePage URL

Posted by Igor Vaynberg <ig...@gmail.com>.
http://wicketstuff.org/wicket13/niceurl/the/homepage/path

but like i said, lets see the full stacktrace, might not even be a wicket
problem

-igor


On 8/31/07, V. Jenks <za...@gmail.com> wrote:
>
>
> I guess I'm completely confused.  I'm pretty sure I've done it this way
> before and it worked fine...but it's been a while.  I've never mounted a
> URL
> before, I'm not familiar w/ it.
>
> I've been going through the Reference Library on the wiki and I can't find
> an example of how to do this and what the URL actually looks like...can
> you
> maybe point me to some instructions?
>
> Thanks!
>
>
> Eelco Hillenius wrote:
> >
> > On 8/31/07, V. Jenks <za...@gmail.com> wrote:
> >>
> >> I'm sure this has been asked 1000x but I'm unable to find the
> >> answer...and
> >> don't have enough time left to keep digging.
> >>
> >> I simply want to call a bookmarkable page and pass it a parameter
> >> value...
> >>
> >> I got this far but my guesses have so far been wrong:
> >>
> >> ?wicket:bookmarkablePage=:com.myapp.BookmarkedPage&catid=1
> >>
> >> I get this error:
> >>
> >> "ERROR [RequestCycle] Can't instantiate page using constructor public
> >> com.myapp.BookmarkedPage(wicket.PageParameters) and argument catid =
> "1""
> >
> > That looks like there is a problem constructing your page, not so much
> > the format. Could you look further in your stack trace? Does
> > BookmarkedPage has a public default constructor or one with just a
> > page parameters argument?
> >
> > Btw, if you mount your pages (per package or individually), it is a
> > bit easier to test.
> >
> > Eelco
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
> > For additional commands, e-mail: users-help@wicket.apache.org
> >
> >
> >
>
> --
> View this message in context:
> http://www.nabble.com/BookmarkablePage-URL-tf4362196.html#a12434374
> Sent from the Wicket - User mailing list archive at Nabble.com.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
> For additional commands, e-mail: users-help@wicket.apache.org
>
>

Re: BookmarkablePage URL

Posted by "V. Jenks" <za...@gmail.com>.
I guess I'm completely confused.  I'm pretty sure I've done it this way
before and it worked fine...but it's been a while.  I've never mounted a URL
before, I'm not familiar w/ it.

I've been going through the Reference Library on the wiki and I can't find
an example of how to do this and what the URL actually looks like...can you
maybe point me to some instructions?

Thanks!


Eelco Hillenius wrote:
> 
> On 8/31/07, V. Jenks <za...@gmail.com> wrote:
>>
>> I'm sure this has been asked 1000x but I'm unable to find the
>> answer...and
>> don't have enough time left to keep digging.
>>
>> I simply want to call a bookmarkable page and pass it a parameter
>> value...
>>
>> I got this far but my guesses have so far been wrong:
>>
>> ?wicket:bookmarkablePage=:com.myapp.BookmarkedPage&catid=1
>>
>> I get this error:
>>
>> "ERROR [RequestCycle] Can't instantiate page using constructor public
>> com.myapp.BookmarkedPage(wicket.PageParameters) and argument catid = "1""
> 
> That looks like there is a problem constructing your page, not so much
> the format. Could you look further in your stack trace? Does
> BookmarkedPage has a public default constructor or one with just a
> page parameters argument?
> 
> Btw, if you mount your pages (per package or individually), it is a
> bit easier to test.
> 
> Eelco
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
> For additional commands, e-mail: users-help@wicket.apache.org
> 
> 
> 

-- 
View this message in context: http://www.nabble.com/BookmarkablePage-URL-tf4362196.html#a12434374
Sent from the Wicket - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org


Re: BookmarkablePage URL

Posted by Eelco Hillenius <ee...@gmail.com>.
On 8/31/07, V. Jenks <za...@gmail.com> wrote:
>
> I'm sure this has been asked 1000x but I'm unable to find the answer...and
> don't have enough time left to keep digging.
>
> I simply want to call a bookmarkable page and pass it a parameter value...
>
> I got this far but my guesses have so far been wrong:
>
> ?wicket:bookmarkablePage=:com.myapp.BookmarkedPage&catid=1
>
> I get this error:
>
> "ERROR [RequestCycle] Can't instantiate page using constructor public
> com.myapp.BookmarkedPage(wicket.PageParameters) and argument catid = "1""

That looks like there is a problem constructing your page, not so much
the format. Could you look further in your stack trace? Does
BookmarkedPage has a public default constructor or one with just a
page parameters argument?

Btw, if you mount your pages (per package or individually), it is a
bit easier to test.

Eelco

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org