[opencms-dev] Cannot save dates earlier than 1970

Carl Alex Friis Nielsen cfn at kb.dk
Sun Jun 29 17:49:46 CEST 2008


You probably just found a bug.
 
Dates are represented internally as milliseconds since the beginning of 1970 (the beginning of time) - it seems OpenCms doesn't know how to handle dates before that - dates before that can be represented by negative numbers.
 
Then there is the issue of how many bits to use - many systems today have problems handling dates after 2038 (stored in seconds rather than milliseconds)
 
Its just like the Y2K problem caused by using two digets for the year in dates.
 
Some might also have an issue with the fact, that leap seconds arent handled (just like we have leap days to handle the year not being exactly 364 times 24 hours long, we need leap seconds to handle that the number of seconds it takes for the earth to rotate once isn't exactly 24  * 60 * 60 - and it even varies a little)
 
IMHO OpenCms should be able to handle it.
 
Will you enter it in the bugzilla or should I ?
 
Cheers,
 
Carl

________________________________

Fra: opencms-dev-bounces at opencms.org på vegne af Marc Schlegel
Sendt: sø 29-06-2008 16:34
Til: The OpenCms mailing list
Emne: [opencms-dev] Cannot save dates earlier than 1970



Hello

I need to store birthday information and the Editor gives me an error (
DoB[1]: ??? GUI_EDITOR_XMLCONTENT_VALIDATION_ERROR_2 ??? ) when I type a
date earlier than 1970.

Example
10.1.1970 14:27 works
10.1.1969 14:27 doesnt work

Its quite urgent, cause I want to publish the site in the next days.

Thanks

_______________________________________________
This mail is sent to you from the opencms-dev mailing list
To change your list options, or to unsubscribe from the list, please visit
http://lists.opencms.org/mailman/listinfo/opencms-dev


-------------- next part --------------
A non-text attachment was scrubbed...
Name: winmail.dat
Type: application/ms-tnef
Size: 5110 bytes
Desc: not available
URL: <https://webmail.opencms.org/pipermail/opencms-dev/attachments/20080629/d94f91d9/attachment.bin>


More information about the opencms-dev mailing list