I have a struts 1.1 app that I am mostly letting myEclipse handle the configuration. I have a basic signon validation that just doesn’t seem to work right. The ActionForm is correctly adding errors such as:
if ((userName == null) || (userName.length() < 1)) {
errors.add(“userName”, new ActionError(“error.username.required”));
errors.add(ActionErrors.GLOBAL_ERROR, new ActionError(“error.username.required”));
}
then in the JSP I have:
<body>
<html:errors/>
….
<td><html:errors property=”userName”/></td>
<td><bean:message key=”message.login.text.username”/></td>
<td><html:text property=”userName”/></td>
But when I don’t supply the user/pass , there is no message other than :
[ServletException in:/webpages/Login.jsp] null’
This code is copied almost directly out of several tutorials and I just can’t see why it doesn’t work. I tried the validation.xml and that also seems broken.
I would really appreciate any pointers anyone can offer.