Hello Matthias,

yes, I mean the automatically generated error messages and their
translation.
An example:
I´m using a validator to check if an email-adress is valid.
Here is the jsf code:

<tr:inputText id="email" label="#{msg['user.email']}"
value="#{registrationBean.user.email}" required="true" >
     <f:validator validatorId="org.apache.myfaces.validator.Email"/>
<tr:message id="emailError" for="email" styleClass="error"/>

If an invalid email adress is entered, the output
"org.apache.myfaces.Email.INVALID" is generated, which I want to change
according to my locale.

I hope my problem is clear now.
Thanks in advance

Santa

        

Matthias Wessendorf-4 wrote:
> 
> Hello Santa,
> 
> are you talking about replacing some "wordings" or "translations" ?
> 
> That is possible w/ a res.bundle;
> You can see in the trinidad-skins.xml in the demo bundle how you can add
> a resource bundle name:
> 
> <skin>
> <id>
> purple.desktop
> </id>
> <family>
> purple
> </family>
> <render-kit-id>
> org.apache.myfaces.trinidad.desktop
> </render-kit-id>
> <style-sheet-name>
> skins/purple/purpleSkin.css
> </style-sheet-name>
> <bundle-name>
> org.apache.myfaces.trinidaddemo.resource.SkinBundle
> </bundle-name>
> </skin>
> 
> And the resource bundle code looks like this:
> 
> package org.apache.myfaces.trinidaddemo.resource;
> 
> import java.util.ListResourceBundle;
> 
> public class SkinBundle extends ListResourceBundle
> {
> @Override
> public Object[][] getContents()
> {
> return _CONTENTS;
> }
> 
> static private final Object[][] _CONTENTS =
> {
> {"af_tableSelectMany.SELECT_COLUMN_HEADER", "Select A Lot"},
> {"af_tableSelectOne.SELECT_COLUMN_HEADER", "Select Just One"},
> ...,
> };
> 
> HTH,
> Matthias
> 
> On Dec 5, 2007 10:08 PM, Santa_Claus <[EMAIL PROTECTED]> wrote:
>>
>> Hello,
>>
>> I want to change the properties of the <tr:message> tag manually. How can
>> this be done?
>>
>> Thanks for your help!
>> --
>> View this message in context:
>> http://www.nabble.com/-Trinidad--messages-tf4952319.html#a14180692
>> Sent from the MyFaces - Users mailing list archive at Nabble.com.
>>
>>
> 
> 
> 
> -- 
> Matthias Wessendorf
> 
> further stuff:
> blog: http://matthiaswessendorf.wordpress.com/
> sessions: http://www.slideshare.net/mwessendorf
> mail: matzew-at-apache-dot-org
> 
> 

-- 
View this message in context: 
http://www.nabble.com/-Trinidad--messages-tf4952319.html#a14193898
Sent from the MyFaces - Users mailing list archive at Nabble.com.

Reply via email to