AttributeModifier
On Sep 30, 2010 8:07 PM, "Ichiro Furusato" <ichiro.furus...@gmail.com>
wrote:
> Hi,
>
> I'm assuming this is a dumb question but I wasn't able to locate an answer
> for what must be an extremely common need. I found the docs on "How to
> modify an attribute on a HTML tag" but that doesn't quite fit, as the
examples
> are all for elements that are themselves created programmatically. Mine is
> solely in markup.
>
> I've got a lot of HTML markup surrounded by a <div> element. The <div>
> element isn't created via Wicket, it's in my HTML file. It has a fair bit
of
> descendent content so I don't want to have to create that via Java, as
> I'm assuming if I put a wicket:id on the <div> element that would replace
> everything within the <div>. I just want to programmatically alter its
'class'
> attribute, but I don't see how this is accomplished.
>
> E.g.,
>
> <div class="foo">
> <table>
> ... etc.
> </table>
> </div>
>
> This would effectively be some kind of query to locate the <div> element,
> then a modification of its 'class' attribute.
>
> Alternately, if I am required to create the <div> element
programmatically,
> how I attach a whole lot of HTML markup to it? Do I have to use a
fragment?
> That seems like a lot of work to just alter an attribute value, so like I
said,
> I must be missing something obvious here...
>
> Ichiro
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> For additional commands, e-mail: users-h...@wicket.apache.org
>