Re: can't set 'id' attribute to tag
Error: WicketMessage: Unable to find component with id 'id' in [MarkupContainer [Component id = idTr]]. This means that you declared wicket:id=id in your markup, but that you either did not add the component to your page at all, or that the hierarchy does not match. Code: JAVA: (colored code here: http://rafb.net/p/D9Hg5838.html) HTML: (http://rafb.net/p/pAao6a88.html) JAVA plain: @AuthorizeInstantiation("ADMIN") public class AdminNavPage extends ThreeColumnBasePage { @SpringBean(name="navigationManager") private NavigationManager navigationManager; public AdminNavPage() { super(); HashMap hashMap = new HashMap(); hashMap.put("date", new Date().toString()); add(new Label("labelText", new StringResourceModel("parametrizedText", this, new Model(new Simple(); List usersNavList = navigationManager.getNavigation(NavigationType.ALL); //TODO implement the list VIEW add(new ListView("listview", usersNavList) { @Override protected void populateItem(ListItem item) { final NavItem navItem = (NavItem) item.getModelObject(); item.add(new WebMarkupContainer("idTr"){ @Override protected void onComponentTag(ComponentTag tag) { super.onComponentTag(tag); tag.put("id", "rowId"+navItem.getId()); } }); item.add(new Label("id", navItem.getId()+"")); item.add(new TextLink("name", new Model(navItem.getName())){ @Override public void onClick() { setResponsePage(navItem.getPageClass()); } }); item.add(new Label("order", navItem.getOrder()+"")); } }); } static class Simple implements Serializable { private String date = new Date().toString(); Simple() { } public String getDate() { return date; } public void setDate(String date) { this.date = date; } } } HTML plain: "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd";> http://www.w3.org/1999/xhtml"; xmlns:wicket="http://wicket.sourceforge.net/"; xml:lang="en" lang="en"> cellspacing="0px" border="0px"> onmouseover="changeC(this.id,'buttonActive');" /> id="actionDisable" class="buttonInactive" type="button" value="Remove" onmouseout="changeC(this.id,'buttonInactive');" onmouseover="changeC(this.id,'buttonActive');" /> cellspacing="2px" border="0px"> type="checkbox" class="tableCheckbox"> href="#">Header 1 src="images/list/listHeaderArrowDown.gif" /> href="#">Header 2 src="images/list/listHeaderArrowUp.gif" /> href="#">Header 3 onmouseover="changeLC(this.id,1);" onmouseout="changeLC(this.id,0);"> type="checkbox" class="tableCheckbox"> Item 32 id href="#"> Item 32 caption Item 32 status it should be webmarkupcontainer, and it should work just fine. paste your complete code with markup and markupcontainer for the whole page/panel. -igor On Sat, Apr 18, 2009 at 4:03 AM, Khlystov Alexandr wrote: Hello again! I can't set 'id' attribute to the tag: WicketMessage: Expected close tag for JAVA: add(new ListView("listview", usersNavList) { @Override protected void populateItem(ListItem item) { final NavItem navItem = (NavItem) item.getModelObject(); item.add(new WebComponent("idTr"){ @Override protected void onComponentTag(ComponentTag tag) { super.onComponentTag(tag); tag.put("id", "rowId"+navItem.getId()); } }); ... HTML: Item 32 id Item 32 caption Item 32 status
Re: wicket-ajax and IE performance problems for pages with many links
I have tracked down the issues in slow IE performance when adding focus events to 1000's of elements. I created a simple page with 1000 normal links using a listview, then measured the performance of the wicket-ajax.js Wicket.Focus.attachFocusEvent method. It would take about 3000ms on page load, and around 500ms on each ajax response (tested using a simple ajax link that does nothing in the onClick() method). When the focus event is added to an element in IE, wicket-event.js Wicket.Event.getId will add an id to any element that does not have one. This takes 2200ms for my test page. If use setOutputMarkupId(true) on my links, then Wicket.Event.getId doesn't create one, and the Wicket.Focus.attachFocusEvent time drops to 700ms the ajax response time is unaffected. NOTE: if you create millions of links, make sure you use .setOutputMarkupId(true) so this focus code doesn't have to create one for you. We can get these numbers down by fixing a function in wicket-ajax.js Wicket.Focus.setFocusOnElements: setFocusOnElements: function (elements) { // we need to cache array length because IE will try to recalculate // the collection of elements every time length() is called which can be quite expensive // if the collection is a result of getElementsByTagName or a similar function. var len=elements.length; for (var i=0; i< len; i++) { if (elements[i].wicketFocusSet != true) { Wicket.Event.add(elements[i],'focus',Wicket.Focus.setFocus); Wicket.Event.add(elements[i],'blur',Wicket.Focus.blur); elements[i].wicketFocusSet = true; } } }, Fetching the elements.length once will bring the numbers down to 220ms for page load and 30ms for ajax update. Igor committed the "var len=elements.length;" change into 1.3.x and 1.4.x already, so that should be all good :) As a comparision... firefox takes 70ms for Wicket.Focus.attachFocusEvent on page load and 5ms for ajax response. -jason lea James Carman wrote: Okay, since this code does show that the problem is with the focus stuff and we have conflicting goals here, what are we going to do to move forward? Obviously, the IE JS engine is way too darn slow to handle this code. Is there some optimization we can do here? Should we file a JIRA? Is there one change in particular that made this so slow in IE? Do we back that out until a better alternative is known? Why am I asking so many questions? :) Sorry, too much coffee this morning. 2009/4/17 Peter Gardfjäll : Sure, here goes. I have added both the java and the js file to the same Java package: WicketAjaxJsPatch.java == /** * {...@link IBehavior} that should be added to {...@link Page}s that need to prevent * the page load performance penalty incurred when wicket-ajax.js traverses all * tags in the page markup. * * * For background information, see http://www.nabble.com/wicket-ajax-and-IE-performance-problems-for-pages-with-many-links-td23078336.html"; * >this mailing list thread * * This behavior simply makes sure that our patch gets applied to wicket-ajax.js * (by forcing wicket-ajax.js to be added to the page head prior to * wicket-ajax-patch.js). * */ public class WicketAjaxJsPatch extends AbstractDefaultAjaxBehavior { @Override public void renderHead(IHeaderResponse response) { super.renderHead(response); response.renderJavascriptReference(new ResourceReference( WicketAjaxJsPatch.class, "wicket-ajax-patch.js")); } @Override protected void respond(AjaxRequestTarget target) { // Does nothing. The fact that we are extending // AbstractDefaultAjaxBehavior means that we will pull in // wicket-event.js and wicket-ajax.js. The job of this behavior is to // make sure that our wicket-ajax-patch.js script gets added to the page // head after those scripts. } } wicket-ajax-patch.js === /** * Overrides the attachFocusEvent function registered by wicket-ajax.js. * The original version traverses all anchor and button tags on the page * which incurs a major performance penalty on pages with many links. * This version skips these elements in the scanning. */ if (typeof(Wicket) != "undefined") { if (typeof(Wicket.Focus) != "undefined") { // Deregister old attachFocusEvent function handlers = Wicket.Event.domReadyHandlers; filteredHandlers = new Array(); for(i = 0; i < handlers.length; i++) { if (handlers[i] != Wicket.Focus.attachFocusEvent) { filteredHandlers.push(handlers[i]); } } Wicket.Event.domReadyHandlers = filteredHandlers; // Redefine and re-register attachFocusEvent Wicket.Focus.attachFocusEvent=function() { Wicket.Focus.setFocusOnElements(document.getElementsByTagName("input")); Wicket.Focus.setFocusOnElements(document.getElementsByTagName("s
Re: Lazy loading via AJAX on stateless pages?
Using urlFor(...) generates a stateful, session-relative link - unless you call urlFor(Class, PageParameters) - which is stateless because it encodes the class and parameters in the URL. In the other URLs, the state is stored in the session, and the URL is basically a map to navigate the component tree to get back to the component that generated the URL. -- Jeremy Thomerson http://www.wickettraining.com On Sat, Apr 18, 2009 at 4:27 PM, Martin Grotzke < martin.grot...@javakaffee.de> wrote: > What exactly causes the page to be stateful when urlFor(Component, > Interface) is invoked? > > I would like to make only minimal changes compared to original wicket > ajax handling and would really like to reuse as much as possible of > wicket ajax handling (e.g. adding components to be updated to the > AjaxRequestTarget). > > Do you think it would be possible to create a Behavior that uses a > callback url which links to a (stateless) page with page parameters. > This page provides a constructor taking parameters and sets an > AjaxRequestTarget on the RequestCycle. It creates and adds all > components which shall be changed to the target. > > What do you think? Can you imagine other ways of being as close as > possible to wicket? > > Thanx && cheers, > Martin > > > > On Fri, 2009-04-17 at 15:40 -0700, Igor Vaynberg wrote: > > sure, you can use behaviors and requesttargets of whatever kind. just > > make sure nothing on your page calls urlfor(component, interface) - > > this is what causes the page to be stateful. > > > > -igor > > > > On Fri, Apr 17, 2009 at 3:14 PM, Martin Grotzke > > wrote: > > > Wow, very fast response! > > > > > > Is it possible to use wicket concepts like RequestTarget and Behavior > on > > > the serverside? I'd like to have this integrated with wicket as much as > > > possible. > > > > > > Cheers, > > > Martin > > > > > > > > > On Fri, 2009-04-17 at 14:55 -0700, Igor Vaynberg wrote: > > >> you cannot use wicket ajax facilities as they are designed for > > >> stateful pages - the link that wicket uses for ajax callback is > > >> inherently stateful. > > >> > > >> what you can do is write javascript yourself using jquery, or > > >> something else to perform an ajax callback to some url you control and > > >> then replace some markup on your page with returned markup. > > >> > > >> -igor > > >> > > >> On Fri, Apr 17, 2009 at 2:52 PM, Martin Grotzke > > >> wrote: > > >> > Hello, > > >> > > > >> > can somebody help with this? > > >> > > > >> > Thanx && cheers, > > >> > Martin > > >> > > > >> > > > >> > On Mon, 2009-04-13 at 12:16 +0200, martin.grot...@javakaffee.dewrote: > > >> >> Hi, > > >> >> > > >> >> I'm currently evaluating how it's possible to have stateless pages > with > > >> >> some information loaded asynchronously via AJAX. > > >> >> > > >> >> I found these postings that are somehow related to this > > >> >> http://www.nabble.com/Stateless-AJAX-links-td20031309.html > > >> >> > http://www.nabble.com/Directions-for-Stateless-Ajax-td17518987.html > > >> >> > > >> >> but I'm not sure what exactly has to be done to achieve what I > want. > > >> >> > > >> >> Basically I have a simple page where I added an AjaxBehavior to a > label > > >> >> that shall get replaced via AJAX: > > >> >> > > >> >> final Label label = new Label( "info", "foo" ); > > >> >> add( label.setOutputMarkupId( true ) ); > > >> >> label.add(new AbstractDefaultAjaxBehavior() { > > >> >> > > >> >> @Override > > >> >> protected void respond( AjaxRequestTarget target ) { > > >> >> final Label lazyLabel = new Label( "info", "loaded > asynchronously" ); > > >> >> Index.this.replace( lazyLabel.setOutputMarkupId( true ) ); > > >> >> target.addComponent( lazyLabel ); > > >> >> } > > >> >> > > >> >> @Override > > >> >> public void renderHead( IHeaderResponse response ) { > > >> >> super.renderHead( response ); > > >> >> response.renderOnDomReadyJavascript( > getCallbackScript().toString() ); > > >> >> } > > >> >> > > >> >> } ); > > >> >> > > >> >> This turns the previously statelesss page to stateful, AFAICS > because of > > >> >> getStatelessHint( Component component ) > > >> >> returning false for the label. > > >> >> > > >> >> When I change this to return true, wicket says the page is expired > on the AJAX request... > > >> >> > > >> >> Can anybody say what had to be done? > > >> >> > > >> >> Btw: I'm using wicket-1.4-SNAPSHOT. > > >> >> > > >> >> Thanx in advance, > > >> >> cheers, > > >> >> Martin > > >> >> > > >> >> > > >> >> > - > > >> >> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org > > >> >> For additional commands, e-mail: users-h...@wicket.apache.org > > >> >> > > >> > > > >> > > >> - > > >> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org > > >> For additional commands, e-mail: users-h...@wick
Re: LinkTree breaks when using twice instances of Firefox (with Unexpected RuntimeException)
Hi I've just spotted the same behavior within the wicket examples page itself, there : http://www.wicket-library.com/wicket-examples/ajax/tree/simple.1 Open two tabs/windows of the same browser and then play with the tree in one page and then the others, then it'll fail "internal error" it says... In fact the state of the tree seems to be shared among the two pages : do some changes on one page and then refresh the other page (with F5), it'll have the state of the previous one. Is it an expected behavior for you ? If so, could someone tell me why and if it's possible to avoid it ? thanks in advance nono 2009/4/17, Live Nono : > Hi > > I'm still working on this tree need and I've discovered this issue : > - opening the page tree in Firefox (or Iceweasel in my ubuntu) > - navigating the tree > - opening the page tree in another tab or instance of firefox > - navigating the tree in this second instance > - when willing again to navigate in the first page, it breaks with an > Unexpected RuntimeException > > However, browsing in 2 different browsers at the same time isn't an > issue (at least with Iceweasel and epiphany, the gnome web browser). > When using 2 epiphany (tabs or instances) at the same time, the issue > is the same. > > My detailed config is Mozilla/5.0 (X11; U; Linux i686; en-US; > rv:1.9.0.7) Gecko/2009032803 Iceweasel/3.0.6 (Debian-3.0.6-1) with > iceweasel 3.0.6 and epiphany/gnome web browser 2.22.3 > > The page in question is heavy on the Ajax side, so perhaps it isn't > directly TreeLink related. > > Am I missing something or... ? > > Thanks in advance > nono > - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: Lazy loading via AJAX on stateless pages?
What exactly causes the page to be stateful when urlFor(Component, Interface) is invoked? I would like to make only minimal changes compared to original wicket ajax handling and would really like to reuse as much as possible of wicket ajax handling (e.g. adding components to be updated to the AjaxRequestTarget). Do you think it would be possible to create a Behavior that uses a callback url which links to a (stateless) page with page parameters. This page provides a constructor taking parameters and sets an AjaxRequestTarget on the RequestCycle. It creates and adds all components which shall be changed to the target. What do you think? Can you imagine other ways of being as close as possible to wicket? Thanx && cheers, Martin On Fri, 2009-04-17 at 15:40 -0700, Igor Vaynberg wrote: > sure, you can use behaviors and requesttargets of whatever kind. just > make sure nothing on your page calls urlfor(component, interface) - > this is what causes the page to be stateful. > > -igor > > On Fri, Apr 17, 2009 at 3:14 PM, Martin Grotzke > wrote: > > Wow, very fast response! > > > > Is it possible to use wicket concepts like RequestTarget and Behavior on > > the serverside? I'd like to have this integrated with wicket as much as > > possible. > > > > Cheers, > > Martin > > > > > > On Fri, 2009-04-17 at 14:55 -0700, Igor Vaynberg wrote: > >> you cannot use wicket ajax facilities as they are designed for > >> stateful pages - the link that wicket uses for ajax callback is > >> inherently stateful. > >> > >> what you can do is write javascript yourself using jquery, or > >> something else to perform an ajax callback to some url you control and > >> then replace some markup on your page with returned markup. > >> > >> -igor > >> > >> On Fri, Apr 17, 2009 at 2:52 PM, Martin Grotzke > >> wrote: > >> > Hello, > >> > > >> > can somebody help with this? > >> > > >> > Thanx && cheers, > >> > Martin > >> > > >> > > >> > On Mon, 2009-04-13 at 12:16 +0200, martin.grot...@javakaffee.de wrote: > >> >> Hi, > >> >> > >> >> I'm currently evaluating how it's possible to have stateless pages with > >> >> some information loaded asynchronously via AJAX. > >> >> > >> >> I found these postings that are somehow related to this > >> >> http://www.nabble.com/Stateless-AJAX-links-td20031309.html > >> >> http://www.nabble.com/Directions-for-Stateless-Ajax-td17518987.html > >> >> > >> >> but I'm not sure what exactly has to be done to achieve what I want. > >> >> > >> >> Basically I have a simple page where I added an AjaxBehavior to a label > >> >> that shall get replaced via AJAX: > >> >> > >> >> final Label label = new Label( "info", "foo" ); > >> >> add( label.setOutputMarkupId( true ) ); > >> >> label.add(new AbstractDefaultAjaxBehavior() { > >> >> > >> >> @Override > >> >> protected void respond( AjaxRequestTarget target ) { > >> >> final Label lazyLabel = new Label( "info", "loaded > >> >> asynchronously" ); > >> >> Index.this.replace( lazyLabel.setOutputMarkupId( true ) ); > >> >> target.addComponent( lazyLabel ); > >> >> } > >> >> > >> >> @Override > >> >> public void renderHead( IHeaderResponse response ) { > >> >> super.renderHead( response ); > >> >> response.renderOnDomReadyJavascript( > >> >> getCallbackScript().toString() ); > >> >> } > >> >> > >> >> } ); > >> >> > >> >> This turns the previously statelesss page to stateful, AFAICS because of > >> >> getStatelessHint( Component component ) > >> >> returning false for the label. > >> >> > >> >> When I change this to return true, wicket says the page is expired on > >> >> the AJAX request... > >> >> > >> >> Can anybody say what had to be done? > >> >> > >> >> Btw: I'm using wicket-1.4-SNAPSHOT. > >> >> > >> >> Thanx in advance, > >> >> cheers, > >> >> Martin > >> >> > >> >> > >> >> - > >> >> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org > >> >> For additional commands, e-mail: users-h...@wicket.apache.org > >> >> > >> > > >> > >> - > >> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org > >> For additional commands, e-mail: users-h...@wicket.apache.org > >> > > > > - > To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org > For additional commands, e-mail: users-h...@wicket.apache.org > signature.asc Description: This is a digitally signed message part
Re: Adding components to Pages based on conditionals
On 17-Apr-09, at 1:00 AM, Subramanian Murali wrote: Hi, I am a new wicket user. How do we include / exclude content or components in pages based on conditions. What is the equivalent in Wicket to the if tag in the JSTL tag library? The reason i ask this question is because irrespective of whether i add the component in the page, i need to have the markup for the component in the HTML. Thanks in advance for the answers. Thanks, Subbu. Take a look at Component#setOutputMarkupPlaceholderTag(boolean) as well, very useful in situations where you want to have something invisible, then add a bunch of stuff to it through an ajax call and have that stuff "show up". Craig. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: lazy load panel in 1.2
have you tried simply adapting the code just for the lazy panel? -igor On Fri, Apr 17, 2009 at 11:42 PM, gaoxm wrote: > Hi, > > I want to do the same thing as AjaxLazyLoadPanel which can allow a panel to > be loaded lazily and is available since 1.3. We want to do that because one > panel in our homepage takes a little longer time and hence the homepage is > quite slow to the end users. > > But the project is based on old 1.2 wicket. It's difficult for us to upgrade > wicket to higher version 1.3 or later at this moment. Is there any easy way > to implement similar function in wicket 1.2? Thanks a lot. > > --Simon > - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: can't set 'id' attribute to tag
it should be webmarkupcontainer, and it should work just fine. paste your complete code with markup and markupcontainer for the whole page/panel. -igor On Sat, Apr 18, 2009 at 4:03 AM, Khlystov Alexandr wrote: > > Hello again! > > I can't set 'id' attribute to the tag: > > WicketMessage: Expected close tag for onmouseout="changeLC(this.id,0);" class="itemsTableTr" wicket:id="idTr" > onmouseover="changeLC(this.id,1);"> > > JAVA: > add(new ListView("listview", usersNavList) { > @Override > protected void populateItem(ListItem item) { > final NavItem navItem = (NavItem) item.getModelObject(); > item.add(new WebComponent("idTr"){ > > @Override > protected void onComponentTag(ComponentTag tag) { > super.onComponentTag(tag); > tag.put("id", "rowId"+navItem.getId()); > } > }); > ... > > HTML: > > onmouseover="changeLC(this.id,1);" > onmouseout="changeLC(this.id,0);"> > class="tableCheckbox"> > Item 32 id > > Item 32 caption > Item 32 > status > > > > > > > > > > > I've tried WebComponent to reference the tag in my sample - it doesn't > work, also I tried WebMarkupContainer - but fails too with this error: > > WicketMessage: Unable to find component with id 'id' in [MarkupContainer > [Component id = idTr]]. This means that you declared wicket:id=id in your > markup, but that you either did not add the component to your page at all, > or that the hierarchy does not match. > > > > JAVA diff: > > - item.add(new WebComponent("idTr"){ > + item.add(new WebMarkupContainer("idTr"){ > > > > > > Thanks in advance. > > > -- > Khlystov Alexandr > > > - > To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org > For additional commands, e-mail: users-h...@wicket.apache.org > > - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: Markup's isVisible method being called multiple times
Oh. I feel stupid haha Thanks. tohtori wrote: > > Hi Henrique, > > Answer can be found from javadoc > > /** > * Gets whether this component and any children are visible. > * > * *WARNING: this method can be called multiple times during a > request. If you override this* > * method, it is a good idea to keep it cheap in terms of > processing. Alternatively, you can > * call {...@link #setVisible(boolean)}. > * > * > * @return True if component and any children are visible > */ > public boolean isVisible() > { > return getFlag(FLAG_VISIBLE); > } > > -MSi > > > Henrique Boregio wrote: >> I am overriding the link's onVisible method to do some conditional >> markup. I've realized that this method is actually being call 4 times. >> When I add a simple System.out to the following code, I get the >> corresponding resut: >> >> >> MyPAGE.JAVA >> >> public class MyPage extends WebPage { >> public MyPage(final PageParameters parameters) { >> >> add(new Link("link") { >> public boolean isVisible() { >>System.out.println("here i am"); >>return false; >> } >> } >> } >> } >> >> PAGE.HTML >> >> # The Link >> >> >> RESULT >> here i am >> here i am >> here i am >> here i am >> >> Any ideas why this method is being called 4 times? >> Thanks. >> > > > > > - > To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org > For additional commands, e-mail: users-h...@wicket.apache.org > -- View this message in context: http://www.nabble.com/Markup%27s-isVisible-method-being-called-multiple-times-tp23114670p23114933.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: Markup's isVisible method being called multiple times
Hi Henrique, Answer can be found from javadoc /** * Gets whether this component and any children are visible. * * *WARNING: this method can be called multiple times during a request. If you override this* * method, it is a good idea to keep it cheap in terms of processing. Alternatively, you can * call {...@link #setVisible(boolean)}. * * * @return True if component and any children are visible */ public boolean isVisible() { return getFlag(FLAG_VISIBLE); } -MSi Henrique Boregio wrote: I am overriding the link's onVisible method to do some conditional markup. I've realized that this method is actually being call 4 times. When I add a simple System.out to the following code, I get the corresponding resut: MyPAGE.JAVA public class MyPage extends WebPage { public MyPage(final PageParameters parameters) { add(new Link("link") { public boolean isVisible() { System.out.println("here i am"); return false; } } } } PAGE.HTML The Link RESULT here i am here i am here i am here i am Any ideas why this method is being called 4 times? Thanks. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Markup's isVisible method being called multiple times
I am overriding the link's onVisible method to do some conditional markup. I've realized that this method is actually being call 4 times. When I add a simple System.out to the following code, I get the corresponding resut: MyPAGE.JAVA public class MyPage extends WebPage { public MyPage(final PageParameters parameters) { add(new Link("link") { public boolean isVisible() { System.out.println("here i am"); return false; } } } } PAGE.HTML The Link RESULT here i am here i am here i am here i am Any ideas why this method is being called 4 times? Thanks. -- Henrique Boregio - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: [poll] Interest in regular Deventer Wicket meetup?
+1 First of all thanks for the effort and the initiative. Although the location is -1 for me, I find this a "wicked" initiative. I just finished reading some chapters of the book, but nothing beats a live session. And the location is actually not that bad, considering the fact that its close to the station (sorry for all the lease drivers). I'll take some cheese from my hometown (old amsterdam) with me, (goes nice along with the pizza) regards, Jeroen. I'm definitively interested and if my calendar allows me I'll attend. On Apr 17, 2009, at 3:30 PM, Martijn Dashorst wrote: I want to poll if there is an interest in a regular Wicket meetup in Deventer, the Netherlands. We can only host at most ~20 people, so I expect this to be much lower key than the Amsterdam meetups. If there is an interest, I'll prod my employer to see if they are willing to help with space, beamer and possibly pizza. The venue would be one of the Topicus buildings, which are conveniently located in the historical center of Deventer, very close to the train station. The types of presentations/discussions/etc. I'm looking for are rather simple: - show us your product and discuss where/how/why you used and extended wicket - show us how you integrated with hibernate/db4o/ibatis/cayenne/rome/spring/guice/jquery/gmap/ opensocial/... - ask us a question for a problem (with code... ;-) - ... These events would start at ~18:30 with pizza, doors open at 18:00 and presentations starting at 19:00. I'd also like to keep the meetups short, about 90 minutes, or maybe 2 hours (max). This will give people the opportunity to return to home at an appropriate time. Afterwards we could visit one of the bars that serve Topicus Gifkikker. Is this an event you would like to visit? Martijn - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: Google Analytics and Wicket
I think the idea is that they're not switching pages, but switching panels. They'd like each panel to show up as a unique page with its own id? On Sat, Apr 18, 2009 at 4:14 AM, nino martinez wael wrote: > Hmm why are that approach requiring more changes than this other? This > just involves that you change extend webpage to mybasepage, and then > drop the few lines of js in the markup of the mybasepage... > > 2009/4/18 Mariana Bustamante : >> Is there any other method that doesn't mean many changes in my application?? >> Everything is already working fine and adding Google Analytics was supposed >> to be one the final details.. >> >> I was thinking of something like adding the javascript manually into my >> panels, I tried this on the panel to test it but it didn't work: >> >> border.add(new AjaxEventBehavior("onload"){ >> �...@override >> protected void onEvent(AjaxRequestTarget target) { >> if(!tracked){ >> String jsGoogle = "if >> (http_request.readyState == 4) { if (http_request.status == 200) { >> alert(http_request.responseText); >> pageTracker._trackPageview('"+GOOGLE_NAME+"' ); } else { alert('Error.'); "; >> >> target.addComponent(border); >> >> target.appendJavascript(jsGoogle); >> tracked = true; >> } >> } >> >> }); >> >> any more ideas? >> >> Thanks in advance, >> >> Mariana >> >> On Sat, Apr 18, 2009 at 5:28 PM, nino martinez wael < >> nino.martinez.w...@gmail.com> wrote: >> >>> If you use markup inheritance just drop it in the parent page.. And >>> there you go.. :) If not.. Well this is a good reason to start :) >>> Works like a snug for my applications >>> >>> 2009/4/17 Mariana Bustamante : >>> > Hello, >>> > >>> > I'm trying to use Google Analytics with my web application made using >>> > Wicket. The layout of my application is like this: >>> > >>> > I have a global plage called "homePage" that contains some panels inside. >>> > One of the panels is a menu which is completely made in java code using >>> > Wicket, the other important panel is the content panel that changes to a >>> > different panel with Ajax every time a user clicks a button on the menu. >>> > >>> > I tried placing the Google Analytics script at the bottom of the homePage >>> > but, as expected, in the generated report I can only see this page. >>> However, >>> > I need to be able to view every panel as a different page. >>> > >>> > There is a link in the google analytics suppport page that seems like >>> what >>> > I'm looking for ( >>> > >>> http://www.google.com/support/googleanalytics/bin/answer.py?hl=en&answer=55519 >>> ) >>> > but I can't see where to put the code they give since the links in my >>> menu >>> > are generated by Wicket in java code and not in html. >>> > >>> > I would really appreciate any help to solve this problem, >>> > >>> > Thanks in advance, >>> > >>> > Mariana >>> > >>> >>> - >>> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org >>> For additional commands, e-mail: users-h...@wicket.apache.org >>> >>> >> > > - > To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org > For additional commands, e-mail: users-h...@wicket.apache.org > > - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: Problem in creating a Custom Component with a Panel and a Form
It's time to change my glasses. :-) Sorry for the stupid question... Thanks a lot Gabriel Giampiero 2009/4/18 Khlystov Alexandr : > > :). > Gabriel Bucher пишет: >> >> write wicket with a 't' instead of a 'd' in the markup. >> for example: >> >> ^ >> >> cheers gab >> >> Giampiero Granatella wrote: >>> >>> Hi, I'm new to wicket and i'm trying to create a custom component with >>> a panel and inside the panel a form. >>> I've a problem in rendering it. >>> >>> The framework tells me the following RuntimeException. >>> >>> "...WicketMessage: The component(s) below failed to render. A common >>> problem is that you have added a component in code but forgot to >>> reference it in the markup (thus the component will never be >>> rendered). >>> >>> 1. [MarkupContainer [Component id = form]] >>> 2. [MarkupContainer [Component id = url]] >>> 3. [MarkupContainer [Component id = username]] >>> 4. [MarkupContainer [Component id = password]] >>> 5. [MarkupContainer [Component id = driver]] >>> 6. [MarkupContainer [Component id = db]] >>> 7. [MarkupContainer [Component id = submit]] >>> >>> ..." >>> >>> But I have that components in the code (see below) >>> >>> # Path Size Type Model Object >>> >>> 2 panel2 2,9K >>> com.manydesigns.portofino.web.components.DBParamPanel >>> 3 panel2:form 2,3K org.apache.wicket.markup.html.form.Form >>> 4 panel2:form:db 1K >>> org.apache.wicket.markup.html.form.TextField >>> 5 panel2:form:driver 1K >>> org.apache.wicket.markup.html.form.TextField >>> 6 panel2:form:jndi 1K >>> org.apache.wicket.markup.html.form.TextField >>> 7 panel2:form:password 1,1K >>> org.apache.wicket.markup.html.form.PasswordTextField >>> 8 panel2:form:submit 4,6K >>> org.apache.wicket.markup.html.form.Button seleziona >>> 9 panel2:form:url 1K >>> org.apache.wicket.markup.html.form.TextField >>> 10 panel2:form:username 1K >>> org.apache.wicket.markup.html.form.TextField >>> >>> And the template for the panel is the following >>> >>> >>> Form >>> >>> >>> >>> >>> >>> >>> >>> >>> >>> >>> >>> >>> >>> >>> >>> >>> Please someone can tell me what I do wrong? >>> >>> Thanks a lot, >>> Giampiero Granatella >>> >>> - >>> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org >>> For additional commands, e-mail: users-h...@wicket.apache.org >>> >>> >>> !DSPAM:49e9a81b171425432119130! >>> >> >> >> - >> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org >> For additional commands, e-mail: users-h...@wicket.apache.org >> >> >> > > > -- > Khlystov Alexandr > > > - > To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org > For additional commands, e-mail: users-h...@wicket.apache.org > > - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: Problem in creating a Custom Component with a Panel and a Form
:). Gabriel Bucher пишет: write wicket with a 't' instead of a 'd' in the markup. for example: ^ cheers gab Giampiero Granatella wrote: Hi, I'm new to wicket and i'm trying to create a custom component with a panel and inside the panel a form. I've a problem in rendering it. The framework tells me the following RuntimeException. "...WicketMessage: The component(s) below failed to render. A common problem is that you have added a component in code but forgot to reference it in the markup (thus the component will never be rendered). 1. [MarkupContainer [Component id = form]] 2. [MarkupContainer [Component id = url]] 3. [MarkupContainer [Component id = username]] 4. [MarkupContainer [Component id = password]] 5. [MarkupContainer [Component id = driver]] 6. [MarkupContainer [Component id = db]] 7. [MarkupContainer [Component id = submit]] ..." But I have that components in the code (see below) # Path Size Type Model Object 2 panel2 2,9K com.manydesigns.portofino.web.components.DBParamPanel 3 panel2:form 2,3K org.apache.wicket.markup.html.form.Form 4 panel2:form:db 1K org.apache.wicket.markup.html.form.TextField 5 panel2:form:driver 1K org.apache.wicket.markup.html.form.TextField 6 panel2:form:jndi 1K org.apache.wicket.markup.html.form.TextField 7 panel2:form:password 1,1K org.apache.wicket.markup.html.form.PasswordTextField 8 panel2:form:submit 4,6K org.apache.wicket.markup.html.form.Button seleziona 9 panel2:form:url 1K org.apache.wicket.markup.html.form.TextField 10 panel2:form:username 1K org.apache.wicket.markup.html.form.TextField And the template for the panel is the following Form Please someone can tell me what I do wrong? Thanks a lot, Giampiero Granatella - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org !DSPAM:49e9a81b171425432119130! - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org -- Khlystov Alexandr - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
can't set 'id' attribute to tag
Hello again! I can't set 'id' attribute to the tag: WicketMessage: Expected close tag for JAVA: add(new ListView("listview", usersNavList) { @Override protected void populateItem(ListItem item) { final NavItem navItem = (NavItem) item.getModelObject(); item.add(new WebComponent("idTr"){ @Override protected void onComponentTag(ComponentTag tag) { super.onComponentTag(tag); tag.put("id", "rowId"+navItem.getId()); } }); ... HTML: Item 32 id Item 32 caption Item 32 status I've tried WebComponent to reference the tag in my sample - it doesn't work, also I tried WebMarkupContainer - but fails too with this error: WicketMessage: Unable to find component with id 'id' in [MarkupContainer [Component id = idTr]]. This means that you declared wicket:id=id in your markup, but that you either did not add the component to your page at all, or that the hierarchy does not match. JAVA diff: -item.add(new WebComponent("idTr"){ +item.add(new WebMarkupContainer("idTr"){ Thanks in advance. -- Khlystov Alexandr - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: Problem in creating a Custom Component with a Panel and a Form
write wicket with a 't' instead of a 'd' in the markup. for example: ^ cheers gab Giampiero Granatella wrote: Hi, I'm new to wicket and i'm trying to create a custom component with a panel and inside the panel a form. I've a problem in rendering it. The framework tells me the following RuntimeException. "...WicketMessage: The component(s) below failed to render. A common problem is that you have added a component in code but forgot to reference it in the markup (thus the component will never be rendered). 1. [MarkupContainer [Component id = form]] 2. [MarkupContainer [Component id = url]] 3. [MarkupContainer [Component id = username]] 4. [MarkupContainer [Component id = password]] 5. [MarkupContainer [Component id = driver]] 6. [MarkupContainer [Component id = db]] 7. [MarkupContainer [Component id = submit]] ..." But I have that components in the code (see below) # PathSizeTypeModel Object 2 panel2 2,9K com.manydesigns.portofino.web.components.DBParamPanel 3 panel2:form 2,3Korg.apache.wicket.markup.html.form.Form 4 panel2:form:db 1K org.apache.wicket.markup.html.form.TextField 5 panel2:form:driver 1K org.apache.wicket.markup.html.form.TextField 6 panel2:form:jndi1K org.apache.wicket.markup.html.form.TextField 7 panel2:form:password1,1K org.apache.wicket.markup.html.form.PasswordTextField 8 panel2:form:submit 4,6K org.apache.wicket.markup.html.form.Button seleziona 9 panel2:form:url 1K org.apache.wicket.markup.html.form.TextField 10 panel2:form:username1K org.apache.wicket.markup.html.form.TextField And the template for the panel is the following Form Please someone can tell me what I do wrong? Thanks a lot, Giampiero Granatella - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org !DSPAM:49e9a81b171425432119130! - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: Problem in creating a Custom Component with a Panel and a Form
Maybe hierarchy doesn't match? Means you added the panel to to other panel at java, but at html panel is added to the page directly. If not please provide more data - your java code. Giampiero Granatella пишет: Hi, I'm new to wicket and i'm trying to create a custom component with a panel and inside the panel a form. I've a problem in rendering it. The framework tells me the following RuntimeException. "...WicketMessage: The component(s) below failed to render. A common problem is that you have added a component in code but forgot to reference it in the markup (thus the component will never be rendered). 1. [MarkupContainer [Component id = form]] 2. [MarkupContainer [Component id = url]] 3. [MarkupContainer [Component id = username]] 4. [MarkupContainer [Component id = password]] 5. [MarkupContainer [Component id = driver]] 6. [MarkupContainer [Component id = db]] 7. [MarkupContainer [Component id = submit]] ..." But I have that components in the code (see below) # PathSizeTypeModel Object 2 panel2 2,9K com.manydesigns.portofino.web.components.DBParamPanel 3 panel2:form 2,3Korg.apache.wicket.markup.html.form.Form 4 panel2:form:db 1K org.apache.wicket.markup.html.form.TextField 5 panel2:form:driver 1K org.apache.wicket.markup.html.form.TextField 6 panel2:form:jndi1K org.apache.wicket.markup.html.form.TextField 7 panel2:form:password1,1K org.apache.wicket.markup.html.form.PasswordTextField 8 panel2:form:submit 4,6K org.apache.wicket.markup.html.form.Button seleziona 9 panel2:form:url 1K org.apache.wicket.markup.html.form.TextField 10 panel2:form:username1K org.apache.wicket.markup.html.form.TextField And the template for the panel is the following Form Please someone can tell me what I do wrong? Thanks a lot, Giampiero Granatella - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org -- Khlystov Alexandr - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Problem in creating a Custom Component with a Panel and a Form
Hi, I'm new to wicket and i'm trying to create a custom component with a panel and inside the panel a form. I've a problem in rendering it. The framework tells me the following RuntimeException. "...WicketMessage: The component(s) below failed to render. A common problem is that you have added a component in code but forgot to reference it in the markup (thus the component will never be rendered). 1. [MarkupContainer [Component id = form]] 2. [MarkupContainer [Component id = url]] 3. [MarkupContainer [Component id = username]] 4. [MarkupContainer [Component id = password]] 5. [MarkupContainer [Component id = driver]] 6. [MarkupContainer [Component id = db]] 7. [MarkupContainer [Component id = submit]] ..." But I have that components in the code (see below) # PathSizeTypeModel Object 2 panel2 2,9K com.manydesigns.portofino.web.components.DBParamPanel 3 panel2:form 2,3Korg.apache.wicket.markup.html.form.Form 4 panel2:form:db 1K org.apache.wicket.markup.html.form.TextField 5 panel2:form:driver 1K org.apache.wicket.markup.html.form.TextField 6 panel2:form:jndi1K org.apache.wicket.markup.html.form.TextField 7 panel2:form:password1,1K org.apache.wicket.markup.html.form.PasswordTextField 8 panel2:form:submit 4,6K org.apache.wicket.markup.html.form.Button seleziona 9 panel2:form:url 1K org.apache.wicket.markup.html.form.TextField 10 panel2:form:username1K org.apache.wicket.markup.html.form.TextField And the template for the panel is the following Form Please someone can tell me what I do wrong? Thanks a lot, Giampiero Granatella - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: how to setup the @SpringBean for the WebSession?
Thanks Cristi! It works, and also I've found that it is usual way seeing the javadoc for : SpringComponentInjector Cristi Manole пишет: Hello, Can you try adding this to the WebSession constructor (or before actually using the bean) : InjectorHolder.getInjector().inject(this); I don't know if this is the usual way of doing things, but it works for me. Cristi Manole On Sat, Apr 18, 2009 at 11:28 AM, Khlystov Alexandr wrote: Hi all! Qustion: how to setup the @SpringBean for the WebSession? I am folowing this guide: http://cwiki.apache.org/WICKET/spring.html#spring-us...@springbeanbeyondwicket I have defined a simple bean: ... ... and at WebApplication code: ... protected void init() { super.init(); addComponentInstantiationListener(new SpringComponentInjector(this)); ... it works correctly for WebPage: ... public class Left3ColumnPanel extends Panel{ @SpringBean(name="navigationManager") private NavigationManager navigationManager; ... but it doesn't work for session: ... public class HelloWebappWebSession extends AuthenticatedWebSession{ ... @SpringBean(name="navigationManager") private NavigationManager navigationManager; ... I've got the java.lang.NullPointerException at org.ovservice.hellowebapp.web.HelloWebappWebSession.authenticate(HelloWebappWebSession.java:47) How can I use beans in WebSession? and maybe in some classes which are not the Wicket components. Thanks in advance! -- Khlystov Alexandr - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org -- Khlystov Alexandr - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: how to setup the @SpringBean for the WebSession?
Hello, Can you try adding this to the WebSession constructor (or before actually using the bean) : InjectorHolder.getInjector().inject(this); I don't know if this is the usual way of doing things, but it works for me. Cristi Manole On Sat, Apr 18, 2009 at 11:28 AM, Khlystov Alexandr wrote: > > Hi all! > > Qustion: how to setup the @SpringBean for the WebSession? > > I am folowing this guide: > http://cwiki.apache.org/WICKET/spring.html#spring-us...@springbeanbeyondwicket > > I have defined a simple bean: > ... > class="org.ovservice.hellowebapp.manager.NavigationManagerImpl"> > > > > > ... > and at WebApplication code: > ... > protected void init() { > super.init(); > addComponentInstantiationListener(new SpringComponentInjector(this)); > ... > > it works correctly for WebPage: > ... > public class Left3ColumnPanel extends Panel{ > > @SpringBean(name="navigationManager") > private NavigationManager navigationManager; > ... > > but it doesn't work for session: > ... > public class HelloWebappWebSession extends AuthenticatedWebSession{ > ... > @SpringBean(name="navigationManager") > private NavigationManager navigationManager; > ... > > I've got the > > java.lang.NullPointerException >at > org.ovservice.hellowebapp.web.HelloWebappWebSession.authenticate(HelloWebappWebSession.java:47) > > > How can I use beans in WebSession? and maybe in some classes which are not > the Wicket components. > > Thanks in advance! > > > > -- > Khlystov Alexandr > > > - > To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org > For additional commands, e-mail: users-h...@wicket.apache.org > >
how to setup the @SpringBean for the WebSession?
Hi all! Qustion: how to setup the @SpringBean for the WebSession? I am folowing this guide: http://cwiki.apache.org/WICKET/spring.html#spring-us...@springbeanbeyondwicket I have defined a simple bean: ... class="org.ovservice.hellowebapp.manager.NavigationManagerImpl"> ... and at WebApplication code: ... protected void init() { super.init(); addComponentInstantiationListener(new SpringComponentInjector(this)); ... it works correctly for WebPage: ... public class Left3ColumnPanel extends Panel{ @SpringBean(name="navigationManager") private NavigationManager navigationManager; ... but it doesn't work for session: ... public class HelloWebappWebSession extends AuthenticatedWebSession{ ... @SpringBean(name="navigationManager") private NavigationManager navigationManager; ... I've got the java.lang.NullPointerException at org.ovservice.hellowebapp.web.HelloWebappWebSession.authenticate(HelloWebappWebSession.java:47) How can I use beans in WebSession? and maybe in some classes which are not the Wicket components. Thanks in advance! -- Khlystov Alexandr - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: Google Analytics and Wicket
Hmm why are that approach requiring more changes than this other? This just involves that you change extend webpage to mybasepage, and then drop the few lines of js in the markup of the mybasepage... 2009/4/18 Mariana Bustamante : > Is there any other method that doesn't mean many changes in my application?? > Everything is already working fine and adding Google Analytics was supposed > to be one the final details.. > > I was thinking of something like adding the javascript manually into my > panels, I tried this on the panel to test it but it didn't work: > > border.add(new AjaxEventBehavior("onload"){ > �...@override > protected void onEvent(AjaxRequestTarget target) { > if(!tracked){ > String jsGoogle = "if > (http_request.readyState == 4) { if (http_request.status == 200) { > alert(http_request.responseText); > pageTracker._trackPageview('"+GOOGLE_NAME+"' ); } else { alert('Error.'); "; > > target.addComponent(border); > > target.appendJavascript(jsGoogle); > tracked = true; > } > } > > }); > > any more ideas? > > Thanks in advance, > > Mariana > > On Sat, Apr 18, 2009 at 5:28 PM, nino martinez wael < > nino.martinez.w...@gmail.com> wrote: > >> If you use markup inheritance just drop it in the parent page.. And >> there you go.. :) If not.. Well this is a good reason to start :) >> Works like a snug for my applications >> >> 2009/4/17 Mariana Bustamante : >> > Hello, >> > >> > I'm trying to use Google Analytics with my web application made using >> > Wicket. The layout of my application is like this: >> > >> > I have a global plage called "homePage" that contains some panels inside. >> > One of the panels is a menu which is completely made in java code using >> > Wicket, the other important panel is the content panel that changes to a >> > different panel with Ajax every time a user clicks a button on the menu. >> > >> > I tried placing the Google Analytics script at the bottom of the homePage >> > but, as expected, in the generated report I can only see this page. >> However, >> > I need to be able to view every panel as a different page. >> > >> > There is a link in the google analytics suppport page that seems like >> what >> > I'm looking for ( >> > >> http://www.google.com/support/googleanalytics/bin/answer.py?hl=en&answer=55519 >> ) >> > but I can't see where to put the code they give since the links in my >> menu >> > are generated by Wicket in java code and not in html. >> > >> > I would really appreciate any help to solve this problem, >> > >> > Thanks in advance, >> > >> > Mariana >> > >> >> - >> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org >> For additional commands, e-mail: users-h...@wicket.apache.org >> >> > - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: sessionsize of requestlogger
Igor, Thanks for referring to Page#getPageReference. Regarding the reload, I created my own error loading a page. >On Fri, Apr 17, 2009 at 5:49 PM, Bernard wrote: >> I prefer not to instantiate a page with a non-default constructor >> because it breaks if the user reloads it. How do we pass parameters >> between pages except via query strings which I try to avoid for >> various reasons? > >can you please explain this a bit more? it is perfectly normal to do >setresponsepage(new edituserpage(usermodel)); > >wicket will redirect to a GET url which will always properly load that >instance of the page, not create a new one every time. > >you can pass page references around using Page#getPageReference, >formerly Page#getPageId, and constructing a url to it using >requestcycle.urlfor() method. > >-igor > [snip] - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org