header.add(new AttributeModifier("onclick", true, new Model() {
public Object getObject() {
return "toggleVisibleDetails('" + activityDetailsPanel.getMarkupId() + "');";
}
}));
and in the relevant html file:
function toggleVisibleDetails(id) {
var element = document.getElementById(id);
element.className = element.className == "displayhide" ? "displayshow" : "displayhide";
}
This just simply toggles the CSS style applied to the element (in my case a <div/>) when its clicked.
Seems to work well for me.
On 7/15/06, John Patterson <[EMAIL PROTECTED]> wrote:
Hi,
I need to add a behaviour to a link so that when it is clicked
several other component are made visible. I could do this with an
AJAX link but it seems that this might be better acheived with a
simple bit of client side script.
Is there any existing behaviour to to this sort of thing or should I
write my own?
Thanks,
John.
-------------------------------------------------------------------------
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
--
i like my video games - mamma said they are gonna melt my brains
i like my video games - i don't care what daddy said; they're my reality
- henning pauly
------------------------------------------------------------------------- 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