Problem is that we allready have a model argument; we can't just decide to use it for something specific out of the blue. So, that would mean introducing a second IModel argument, which is plain ugly from an API's point of view. Second problem is that in order to let Link replace it's body, it couldn't be a container anymore. A custom component would be very easy on the other hand... just create a panel with the Link and Label on it. I've used that a couple of times in projects. So, I'm -1. Eelco
-----Oorspronkelijk bericht----- Van: Johan Compagner Verzonden: vr 19-8-2005 15:27 Aan: wicket-user@lists.sourceforge.net CC: Onderwerp: Re: [Wicket-user] HyperLink Text that label should work (like others are pointing out. But we should simplify this. <a wicket:id = "hlink" href="" >Go to my Page</a> Link link = new Link('hlink',new Model("this is my text")); why the extra span between them, mostly the model of the link isn't even used. An extra link class that extends link? (the problem is that onComponentTagBody is final...) johan Dipu wrote: > Hi, > > Is there any way i can dynamically specfy the HyperLink text ? > > Right now if i have a link the markup look like > <a wicket:id = "hlink" href="" >Go to my Page</a> > > I would like to replace the "Go to my Page" link text with some > dynamic content. > I tried adding a label like this <a wicket:id = "hlink" href="" > ><span wicket:id="linkLabel"></span></a> > > But this doesn't seem to work. > Is there anything wrong with the way i am doing it. > > > Regards > Dipu > > > > > > ------------------------------------------------------- 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
<<winmail.dat>>