I want to use
<form action="someClass">
<s:textarea name="name" label="Name"/>
<s:checkboxlist list="{'Male','Female'}" name="gender" label="Gender"/>
</form>
instead of
<s:form action="someClass">
<s:textarea name="name" label="Name"/>
<s:checkboxlist list="{'Male','Female'}" name="gender" label="Gender"/>
</s:form>
Because <s:form>
tag's default theme "xhtml"
is not ok with my CSS and theme "simple"
can't show validation errors by itself without the use of <s:fielderror>
tag.
So is it valid to use it?
I'm ok by using like that till now. Is there any error that I will face for using like that in the future?
Of course you can use plain HTML tags.
Please remember that all JSP custom tags do, in the end, is render HTML.[1]
As Roman states, you'll lose things like the automatic filling of values, the retrieval of labels via the attribute name or key, the display of error messages and styling, and so on.
Your best course of action may be to create your own theme and use your own templates and CSS, or use the "css_xhtml"
theme, and supply your own styles. Which is better to do depends on a fair amount of information we don't have, but the CSS HTML version is fairly flexible other than having to define the <br/>
tag as being inline because it's currently used in the theme where it shouldn't be.
[1] Yes, it could do other stuff on the server side before sending over HTML, like the SQL custom tags. In general, though, the purpose of custom tags is to emit HTML.