The corresponding Java code would be:

Link link = new Link("hlink") {protected void onClick() {} };
link.add(new Label("linkLabel", "Hello World!"));
add(link);

Or to be specific: you should add the label to the link, and the link to the page (or parent component).

Martijn

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
[email protected]
https://lists.sourceforge.net/lists/listinfo/wicket-user

Reply via email to