Hi,
I have a problem adequately positioning the error message behind the label of an input text field.
Here is the JSF code snippet:
<h:message for="Login">
<h:outputText value="Login "/>
</h:message>
<h:inputText id="Login" value="#{organizer.login}" required="true" disabled="#{organizerAction.managed}"/>
The problem is that, when I leave the textfield completely empty so that there is no value at all, I get:
Login "Login": Input required.
But if I enter too few letters so that the @Length annonation throws a ValidationException, then I get:
Login has to be betwenn 5 and 40 characters.
Seam seems to leave out the name of the input field and JSF does seem to put it into parantheses and add it to the message.
How can I get a consitent message format??
Run seam-gen. It sets up a messages.properties file with example messages.