Hi, Newbee question: I need to add the onload attribute to the body tag (I can't use other methods to accomplish the same thing...)
My html: <html> <wicket:head> ... </wicket:head> <wicket:extend> <body wicket:id="bodyElement"> ... </body> </wicket:extend> </html> Java: WebMarkupContainer body = new WebMarkupContainer("bodyElement"); add(new WebMarkupContainer("bodyElement") { �...@override public boolean isTransparentResolver() { return true; } �...@override protected void onComponentTag(final ComponentTag tag) { super.onComponentTag(tag); tag.put("onload", "onload();"); } }); Result html: <html> <head> ... </head> <body> <body onload="onload();"> ... I now have two body start tags. The code below results in a runtime exception stating that bodyElement was not declared.. <body wicket:id="bodyElement"> <wicket:extend> ... </wicket:extend> </body> </html> I have also tried adding: add(new BodyTagAttributeModifier("onload", true, new Model("onload();"), this)); But nothing gets added to the body tag. Can someone direct me in the right direction? Wicket version: 1.4.1 JDK: IBM JDK 5.0.10 Regards, Jess --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org