I have a question about the possibility of "overloading" s:selectDate month and weeknames?
I was searching for the subject and I found this ( http://jira.jboss.org/jira/browse/JBSEAM-623 )
- Day and month names are localised as well.
So it seams that there is already a way to redefine the names for a specific language (based on the localization - locale) (correct me if I'm wrong :)
There are any examples??
This is localised through java.text.DateFormatSymbols so I don't think you can arbitrarily override the strings (but read up on DateFormatSymbols).
Thanks for the reply Pete.
Originally I didn't interpret well what I've read on http://jira.jboss.org/jira/browse/JBSEAM-623 so I didn't understand the right use of s:selectDate.
But after digging on your code (SelectDateRendererBase.java) I got it (how it works...)
I was thinking that s:selectDate needed some sort of *.js locale resource (DateFormatSymbols is powerful).
The truth is that I've define the locale in faces-config.xml like this
<locale-config> <default-locale>pt</default-locale> <supported-locale>pt</supported-locale> </locale-config>
This is also reported in this thread ( http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4035703#4035703 )
and there's a JIRA related ( http://jira.jboss.com/jira/browse/JBSEAM-1156 )
I don't know exactly what is the problem (I've tested with Firefox 126.96.36.199, Opera 9.23 and IE 7 and in all it goes the same. Also [for all] if I made a refresh then the s:selectDate names now appears on portuguese)
Workaround: After putting the next code (through static form) the problem is solved (as is suggested by damianharvey)!!
Sorry if it went too extensive!
s:selectDate will soon be deprecated in favour of rich:calendar so use the workaround.
Ok, thanks for your time Pete!