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 <[EMAIL PROTECTED]> 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 <[EMAIL PROTECTED]> 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: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



--
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: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]





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

Reply via email to