Using the button element in normal HTML you can do the following:
<button type="submit">
<img src="/images/icons/tick.png" alt=""/> Save
</button>
which gives you an icon along with the label on the button itself.
When I attempt to try the same thing using S2 tags e.g.
<s:submit theme="simple" type="button">
<img src="/images/icons/tick.png" alt=""/> Save
</s:submit>
is gets rendered in the following way:
<img src="/images/icons/tick.png" alt=""/>Save
<button type="submit" id="someForm_0" value="Submit">Submit</button>
I also have tried using the following inside the body with no luck.
<s:param name="body">
<img src="/images/icons/tick.png" alt=""/> Save
</s:param>
How can I add an icon to my button?
I do not understand why any text in the tag body gets pushed out to the
front of the tag.
Thanks for any help on this!
--
View this message in context:
http://www.nabble.com/S2-Cannot-get-Submit-button-body-to-render-as-label...-tf4517335.html#a12885678
Sent from the Struts - User mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]