tags:

views:

312

answers:

1

If I use a span tag to render a component like <span jwcid="@If" .../>, my HTML ends up with a bunch of useless span tags. Most of the time, that's ok, but in some cases, it's interfering with my CSS or making the page invalid. Is there a way to tell Tapestry to process the tag, but not actually render it?

+2  A: 

Take a look at org.apache.tapestry.renderTags Tapestry configuration property:

Specifies whether or not some block level components will render their template tag names by default.

This currently affects the If, Else and For components.

You can also specify the renderTag parameter for a particular component instance, see the If component documentation.

Jan Soltis
Took me a while to get around to testing this but renderTag="false" did exactly what I wanted. Thanks!
Brian Deterling
You should be aware that changing this property in the configuration breaks some built-in Tapestry components (such as the default exception page) in all versions where the property exists up to 4.1.5. See https://issues.apache.org/jira/browse/TAPESTRY-1431
Robert J. Walker