cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Johnson" <john...@soho.club.tw>
Subject Re: Problems with CForms
Date Sat, 04 Sep 2004 02:34:48 GMT
Hi:

I've the same problem too,I do some exam and found that's the daylight time
problem in the date input in javascript

1.if you input a summer time,the hour will -1 automatically,so your input
1993-10-15,it must be 1993-10-15 0:00:00,be the system will -1 hour to
1993-10-14 23:00:00
2.if you set the default value of cfome date,don't modify it,and save to
datebase,it'll be ok.
3.non summer time ok.
4.if you install cocoon in windows plateform , add the registry
HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Control\TimeZoneInformation
to "DisableAutoDaylightTimeSet"=dword:00000001 it will ok to every time.

I've send this msg to bugzilla 30372,but the error is not solve still.
it's the bug for date.js in resources\mattkruse-lib I think, you can see it
and consider how to do,I you solve it pls let me know.

Best regards

johnson



----- Original Message ----- 
From: "Jakub Kaniewski" <jkan@egonet.pl>
To: <users@cocoon.apache.org>
Sent: Saturday, September 04, 2004 9:58 AM
Subject: Problems with CForms


> Recently I discovered some strange behavior of cforms. I have a date
> element in my form, in most cases entered date is correctly passed to
> bind etc. But some dates are modyfied by CForms engine (?) and are bad.
>  For example date 1993-10-15 change into 1993-10-14. Most often the
> broker date is decreased by one day from correct, but sometimes it is
> decreased by one month.
> I performed several test and I think it is some issue connected with
> FormattingDateConvertor class. I tried to spot error again outside
> cocoon, but my efforts was unsuccesful. So I focused back on Cocoon and
> I began debugging Flowscript with Rhino debugger. And I have this
> results (these are examples copy from watches window):
>
> INPUT :
> this.getChild("DATA").getDatatype().convertFromString("1993-10-15", new
> Packages.java.util.Locale("pl")).getResult()
> RESULT : Thu Oct 14 23:00:00 CET 1993 (error)
>
> INPUT :
> this.getChild("DATA").getDatatype().convertFromString("1993-10-12",
> Packages.java.util.Locale.getDefault()).getResult()
> RESULT : Mon Oct 11 23:00:00 CET 1993 (error)
>
> INPUT:
> this.getChild("DATA").getDatatype().convertFromString("1993-11-12",
> Packages.java.util.Locale.getDefault()).getResult()
> RESULT:Fri Nov 12 00:00:00 CET 1993 (correct)
>
> I have no ideas about the cause of this errors, I think that strange
> hour 23:00:00 (in date filed) suggest that it is some locale and time
> issue. This errors appears in some years most often i autumn months.
>
> I am using Cocoon 2.1.5, the error appears both on Windows and Linux
> machine (JVM SUN 1.4.2).
>
> Regars Jakub Kaniewski
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
> For additional commands, e-mail: users-help@cocoon.apache.org
>


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org


Mime
View raw message