struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Laurie Harper <lau...@holoweb.net>
Subject Re: Struts2 Validation formating error messages
Date Sun, 12 Aug 2007 21:00:37 GMT
WiltOnTilt wrote:
> Hi, I've searched around here and googling to try to find a good answer but I
> haven't found one.
> 
> I'm using the basic struts2 validation with the validate="true" on my
> <s:form> so the validation is done client side.
> 
> I'd like to change the error messages so they do not show up ABOVE my
> controls.  (I dont know about you guys but wow that's so annoying... default
> should have been right or left of the control)...
> 
> I'd like to get the error messages to show up to the right of my control and
> I'd like those messages to be in red.  Alternatively, I wouldn't mind having
> all the errors listed at the top of the page with red *'s next to each
> field.  Either is fine.
> 
> Do I need to create my own version of <s:textfield> to make this happen?  Or
> a new theme perhaps?  If so do you know of any good resources for this?
> 
> I've tried using the <s:actionerror /> tag but nothing ever renders from it?

Customizing whichever theme you are using is probably the easiest way to 
tailor the page layout as you wish. See here for relevant documentation:

http://struts.apache.org/2.x/docs/themes-and-templates.html
http://struts.apache.org/2.x/docs/extending-themes.html

HTH,

L.


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


Mime
View raw message