myfaces-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Sławek Sobótka <sso...@wp.pl>
Subject InputCalendar: replace default date converter
Date Sat, 16 Sep 2006 12:43:32 GMT
thanks. it works fine for h:inputText but not for t:inputCalendar. I 
guess taht inputCalendar has differend model than java.util.Date...?

> 
> you can overwrite all entries in your applications faces-config.xml,
> so just insert this
> 
>     <converter>
>         <converter-id>javax.faces.DateTime</converter-id>
>         <converter-class>[your.converter.class]</converter-class>
>     </converter>
> 
>     <converter>
>         <converter-for-class>java.util.Date</converter-for-class>
>         <converter-class>[your.converter.class]</converter-class>
>     </converter>
> 
> to overwrite the default DateTimeConverter.
> 
> Regards
> 
>     volker
> 
> 2006/9/16, Sławek Sobótka <ssobot@wp.pl>:
> > i would like to let users input date like this: t+5 (that means 5 
days
> > from now). i know that i can write ny own converter, register in i
> > faces-config and use it like this: <t:inputCalendar
> > converter"Tconverter" ...
> >
> > but
> >
> > i dont like it;)
> >
> > i would like to replace default_jsf_date_converter (or whatever it
> > names) by my own converter. i just dont want to traverse all my 
pages
> > and paste converter="TConverter" in every input calendar.
> >
> > how can i do this?
> >
> > ----------------------------------------------------
> > Mega koncert - Duran Duran - Warszawa Służewiec 23 września 
2006!
> > Zdobądź bilet dla siebie i swoich przyjaciół - Kliknij:
> > http://klik.wp.pl/?adr=http%3A%2F%2Fadv.reklama.wp.pl%2Fas%2Fd2.
html&sid=862
> >
> >
> >
> 

----------------------------------------------------
Mega koncert - Duran Duran - Warszawa Służewiec 23 września 2006!
Zdobądź bilet dla siebie i swoich przyjaciół - Kliknij:
http://klik.wp.pl/?adr=http%3A%2F%2Fadv.reklama.wp.pl%2Fas%2Fd2.html&sid=862



Mime
View raw message