You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by dutrieux <du...@pasteur.fr> on 2003/10/31 11:09:38 UTC
euro date
I declare in struts-config.xml a DynaActionForm class with a property
"euroDate" of class java.sql.date.
I register on the ConvertUtils instance a new convert class for the the
class "java.sql.Date" to support the european date (dd.mm.yyyy). That
work very fine.
But now my problem is that I would like display in the <html:text
property="euroDate"> the date : not in usa date (yyyy-mm-dd) but in euro
date (dd.mm.yyyy).
Does any body know a solution.
Best regards
--
------------------------------------------------------------------------
*Olivier Dutrieux*
------------------------------------------------------------------------
<www.pasteur.fr>
------------------------------------------------------------------------
Institut Pasteur
Informatique de gestion
&
Micro-Informatique
25-28 rue du Docteur Roux
75724 PARIS CEDEX 15
------------------------------------------------------------------------
Tel: +33 (0) 1 40 61 31 62
Fax: +33 (0) 1 45 68 89 89
------------------------------------------------------------------------
Re: euro date
Posted by Vic Cekvenich <ce...@baseBeans.com>.
Or you could use formBeans, one of more befits for update.
HOWEVER .... you said display the date (not update), so no need for a
formBean either.
You should localize when ever posible using JSTL fmt tag for dates and
other things.
Mark Lowe wrote:
> Just define the form property as a string
>
> <form-property name="date" type="java.lang.String" />
>
> when you get the date from you model either format it in your referring
> class, using DateFormat.
>
> java.util.Date date = new java.util.Date( dateString );
>
> now you can format and then feed it back to the form.
>
> Cheers Mark
>
>
> On Friday, October 31, 2003, at 10:09 AM, dutrieux wrote:
>
>>
>>
>>
>>
>> I declare in struts-config.xml a DynaActionForm class with a property
>> "euroDate" of class java.sql.date.
>>
>> I register on the ConvertUtils instance a new convert class for the
>> the class "java.sql.Date" to support the european date (dd.mm.yyyy).
>> That work very fine.
>>
>> But now my problem is that I would like display in the <html:text
>> property="euroDate"> the date : not in usa date (yyyy-mm-dd) but in
>> euro date (dd.mm.yyyy).
>>
>> Does any body know a solution.
>>
>> Best regards
>>
>> --
>>
>>
>>
>>
>> Institut Pasteur
>>
>>
>> BODY { MARGIN-TOP: 1em; FONT-SIZE: 12pt; MARGIN-LEFT: 1em; COLOR:
>> #003399; FONT-FAMILY: "Trebuchet MS" }
>>
> <image.tiff>
>
>>
> <image.tiff>
>
>>
> <image.tiff>
>
>>
>> <Institut Pasteur>
--
Victor Cekvenich,
Struts Instructor
(215) 321-9146
Advanced Struts Training
<http://basebeans.com/do/cmsPg?content=TRAINING> Server Side Java
training with Rich UI, mentoring, designs, samples and project recovery
in North East.
Simple best practice basic Portal, a Struts CMS, Membership, Forums,
Shopping and Credit processing, <http://basicportal.com> software, ready
to develop/customize; requires a db to run.
---------------------------------------------------------------------
To unsubscribe, e-mail: struts-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: struts-user-help@jakarta.apache.org
Re: euro date
Posted by Mark Lowe <ma...@talk21.com>.
Just define the form property as a string
<form-property name="date" type="java.lang.String" />
when you get the date from you model either format it in your referring
class, using DateFormat.
java.util.Date date = new java.util.Date( dateString );
now you can format and then feed it back to the form.
Cheers Mark
On Friday, October 31, 2003, at 10:09 AM, dutrieux wrote:
>
>
>
>
> I declare in struts-config.xml a DynaActionForm class with a property
> "euroDate" of class java.sql.date.
>
> I register on the ConvertUtils instance a new convert class for the
> the class "java.sql.Date" to support the european date (dd.mm.yyyy).
> That work very fine.
>
> But now my problem is that I would like display in the <html:text
> property="euroDate"> the date : not in usa date (yyyy-mm-dd) but in
> euro date (dd.mm.yyyy).
>
> Does any body know a solution.
>
> Best regards
>
> --
>
>
>
>
> Institut Pasteur
>
>
> BODY { MARGIN-TOP: 1em; FONT-SIZE: 12pt; MARGIN-LEFT: 1em; COLOR:
> #003399; FONT-FAMILY: "Trebuchet MS" }
>
<image.tiff>
>
<image.tiff>
>
<image.tiff>
>
> <Institut Pasteur>
---------------------------------------------------------------------
To unsubscribe, e-mail: struts-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: struts-user-help@jakarta.apache.org