Re: [Wicket-user] PageParameters settings
Yeah, use QueryStringUrlCodingStrategy, like: String path = "/path/to/page2qpencoded/"; mount(path, new QueryStringUrlCodingStrategy(path, Page2QP.class)); I'm adding an example of this to wicket-examples. Eelco On 9/16/06, Ayodeji Aladejebi <[EMAIL PROTECTED]> wrote: > > I need my WebPage to process page parameters in this format > ?param1=value1¶m2=value2&etc > > the default seems to be /params/value/params/value > > if i have to instantiate my WebPage based on a callback means from another > external application that will send me parameters via those format options, > how do i do it. > > I used nice url mounting > > any tips > > > > - > Using Tomcat but need to do more? Need to support web services, security? > Get stuff done quickly with pre-integrated technology to make your job > easier > Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo > http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 > > ___ > Wicket-user mailing list > Wicket-user@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/wicket-user > > > - Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user
Re: [Wicket-user] PageParameters and Null Values
Agreed. Could you open a bug for this please? Eelco On 9/8/05, Matej Knopp <[EMAIL PROTECTED]> wrote: > Hi. > > I don't know if this has been discussed yet. Using PageParameters and > BookmarkablePageLinks I just found a strange feature. If there is null > in PageParameters for argument foo, the url contains 'foo=null'. > > Is this deliberate? Wouldn't it have more sense if url didn't contain > the foo value at all, so that the foo value for requst parameters would > be null (not 'null')? > > -Matej > > > --- > SF.Net email is Sponsored by the Better Software Conference & EXPO > September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices > Agile & Plan-Driven Development * Managing Projects & Teams * Testing & QA > Security * Process Improvement & Measurement * http://www.sqe.com/bsce5sf > ___ > Wicket-user mailing list > Wicket-user@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/wicket-user > --- SF.Net email is Sponsored by the Better Software Conference & EXPO September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices Agile & Plan-Driven Development * Managing Projects & Teams * Testing & QA Security * Process Improvement & Measurement * http://www.sqe.com/bsce5sf ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user
Re: [Wicket-user] PageParameters
Dzenan Ridjanovic wrote: Could you give us the stracktrace you got? I have changed the code this afternoon and could not reproduce the error. However, I have done something similar and it works: public class UrlsPage extends WebPage ... public UrlsPage(PageParameters pageParameters) { UrlsApp app = (UrlsApp)getApplication(); Urls urls = (Urls) pageParameters.get("categoryUrls"); Please be carefull. PageParameters are meant for bookmarkable pages. So there should be only Strings (or things like Integers that have a simple string presentation) So if you use this page also as a bookmarkable page then that Urls cast will throw a classcast or will return null...!! ... public final void onSubmit() { String enteredCategory = category.getInput(); if (enteredCategory != null) { RequestCycle cycle = getRequestCycle(); PageParameters parameters = new PageParameters(); UrlsApp app = (UrlsApp)getApplication(); Urls urls = app.getUrlsDb().getCategoryUrls(enteredCategory); parameters.put("category", enteredCategory); parameters.put("categoryUrls", urls); cycle.setResponsePage(getPageFactory().newPage(UrlsPage.class, parameters)); cycle.setRedirect(true); } } You are really mis using PageParameters you just should do: cycle.setResponsePage(new UrlsPage(urls)); much simpler. johan --- SF.Net email is sponsored by: Discover Easy Linux Migration Strategies from IBM. Find simple to follow Roadmaps, straightforward articles, informative Webcasts and more! Get everything you need to get up to speed, fast. http://ads.osdn.com/?ad_id=7477&alloc_id=16492&op=click ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user