@Override protected final void onComponentTag(final ComponentTag tag) { tag.setName("input"); tag.put("type", "text");
super.onComponentTag(tag); } Seems to do what I want but is this a valid extension point? In PasswordTextBox and ListChoice it is marked final...? I don't want to stitch my client up with something that is going to break with the next version of Wicket. So although means extra dom elements on the browser and more component instances on the server am I better off wrapping the raw components? Cheers Sam Sam Hough wrote: > > We want to switch an input field between "input type=text" and "textarea" > depending on how large the existing data is. Is there any way to do this > without needing a spurious placeholder element? ie We would rather not > have a "span wicket:id=textInput" but rather just get the "text" or > "textarea" element in the final HTML . > > So anything I can do in onComponentTag etc to change the tag name in the > HTML file? > > Cheers > > Sam > -- View this message in context: http://www.nabble.com/Override-tag-name-in-html-fragment--tp14995403p14999180.html Sent from the Wicket - User mailing list archive at Nabble.com. --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]