You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by Jim Cushing <ji...@mac.com> on 2007/10/03 00:10:08 UTC

[S2] Can a custom component have a body? or, using
with themes

Is something like this legal in a Struts 2 custom component:

     <s:component template="/my/custom/component.vm">
       <s:param name="key1" value="value1"/>
       <s:param name="key2" value="value2"/>
       Some text to be wrapped in my component.
       <s.text name="someProperty" />
     </s:component>


In other words, can <s:component> act like, for example, <s:form>...</ 
s.form>? I'd like to create a HTML fieldset component that plays well  
with themes. But this doesn't result in valid HTML with the xhtml  
theme, for example:

<s:form ...>
	<fieldset>
	<legend>Form test</legend>

	<s:text ... />
</s.form>

If anyone's had luck using <fieldset> with a theme other than simple,  
I'm interested in how you accomplished that.


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org