Hello everyone...
I'm working on a Wicket-based web application. In the application there are buttons that not every user is authorized to use. These buttons are actually simple links, e.g.
<a wicket:id="publishButton" title="Publish" class="rightPanel_publish"><wicket:message key="publish"/></a>
with a CSS class (from an external CSS file) that sets their visual appearance, e.g.
a.rightPanel_publish {
display: block;
width: 90px;
height: 27px;
background: url( ../imgs/right_panel_icon03.gif ) left top repeat-y;
text-decoration: none;
color: black;
padding: 12px 0px 0px 35px;
}
When the user is not authorized to use the button, the link is disabled (in Java) and the CSS, for some reason, is not used anymore.
My question is this: is there a way to identify that the link is disabled at runtime and change the CSS class? I would rather avoid using javascript (managed to keep the entire project JS-free so far...), and prefer something that would work with all browsers.
Thanks a bunch,
Yuval =8-)