struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Brady Hegberg <bra...@bitstream.net>
Subject Re: Setting focus on invalid form submission
Date Mon, 02 May 2005 17:30:24 GMT
I think this would have to be done with Javascript.  And it might be a
bit tricky determining what the first invalid element was.  I think it
would involve setting javascript variables and then looping through the
page looking for the first one with an error.

Unless there's a way to do it with the new errorStyle properties.

Brady

> Relatively new to the list, so I apologize if this has already been 
> submitted.
> 
> I am wondering if there is a way to set the focus after a form has been 
> validated through Struts and deemed invalid?  Currently, focus always 
> goes to the first form element.  Is there not a way to make this go to 
> the first INVALID form element?
> 
> Thanks for any help.
> 
> --
> Randy Kennedy
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
> For additional commands, e-mail: user-help@struts.apache.org
> 
-- 
Brady Hegberg <bradyh@bitstream.net>


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


Mime
View raw message