You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@myfaces.apache.org by "Bruno Aranda (JIRA)" <my...@incubator.apache.org> on 2005/06/09 11:57:27 UTC

[jira] Commented: (MYFACES-279) RegExprValidator Error-Message should show the pattern for better understanding

    [ http://issues.apache.org/jira/browse/MYFACES-279?page=comments#action_12313143 ] 

Bruno Aranda commented on MYFACES-279:
--------------------------------------

Although it can be very helpful for developers when they debug their applications ;-) , I think that a 'technical' message can create confusion in the standard application user (depending on the targeted users, of course ;-)).  It is more helpful to a user to have a comment next to the inputText that says something like "Value must follow pattern 00-XXXX" than an error message that says "The submitted value ({0}) doesn't fit the pattern \d{2}-\D{4}". You can always localize the messages for your situation. As what you need for the message to be shown is the pattern as an argument, I see well the change in the Validator, but I would keep the current myfaces messages and override them when necessary.
Please, could you create the patch using svn diff instead of copying the modified files? This will make things easier for the commiters...

Regards,

Bruno

> RegExprValidator Error-Message should show the pattern for better understanding
> -------------------------------------------------------------------------------
>
>          Key: MYFACES-279
>          URL: http://issues.apache.org/jira/browse/MYFACES-279
>      Project: MyFaces
>         Type: Improvement
>     Reporter: Alex Mayer
>     Priority: Minor
>  Attachments: Messages.properties, Messages_de.properties, Messages_en.properties, RegExprValidator.java
>
> To my mind it would be better, if the regExprValidator's ErrorMessage would show a text like this:
> The submitted value ({0}) doesn't fit the pattern "{1}". 
> Because this gives the user and the developer a more detailed information than "the given value ({0}) is not valid". Here the user/ developer has no information what might be the correct input.
> However, I changed the code of RegExprValidator and the german, english and standard message properties so that the pattern is shown in the error-message.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira