Share » Forums » Developer » "date" attribute limited 1970

"date" attribute limited 1970

"date" attribute limited 1970

Friday 19 October 2007 4:55:48 am - 5 replies

Author Message

André R.

Friday 19 October 2007 5:08:27 am

This is a limitation in the date handling in php, it should be fixed in php 5, so it should in theory work on eZ Publish 4.0 (but I havn't personally tested this yet).

Alternative is to use the birthday-datatype:
http://ez.no/developer/contribs/datatypes/birthday_datatype

Most uptodate version is here:
http://svn.ez.no/svn/extensions/birthday_datatype/

eZ Online Editor 5: http://projects.ez.no/ezoe || eZJSCore (Ajax): http://projects.ez.no/ezjscore || eZ Publish EE http://ez.no/eZPublish/eZ-Publish-Enterprise-Subscription
@: http://twitter.com/andrerom

Santi Castells

Friday 19 October 2007 5:27:06 am

Thanks for your help.

Do you know if the manual change i have made on the kernel will be affecting negatively to the performance of ez? the thing is that the templates are already done with the "date" attribute and i would have to change quite a many if i wanna change the attribute type.

André R.

Friday 19 October 2007 5:43:02 am

Probably not.
But have you tested saving dates prior to 1970 after the kernel hack?
If so, what php version are you on?

eZ Online Editor 5: http://projects.ez.no/ezoe || eZJSCore (Ajax): http://projects.ez.no/ezjscore || eZ Publish EE http://ez.no/eZPublish/eZ-Publish-Enterprise-Subscription
@: http://twitter.com/andrerom

Santi Castells

Friday 19 October 2007 5:52:15 am

I changed it already and the specifically form works well, but don't know about general perfomance.
My php version is 4.4.7.

Thanks

Laurent BOURREL

Friday 19 October 2007 6:04:13 am

Hi,

I think it would be better to use a custom datatype than to modify the kernel...

For example :
http://ez.no/developer/contribs/datatypes/birthday_datatype

UPDATE : Oups, didn't see that the contrib was already posted, sorry guys :)

You must be logged in to post messages in this topic!

36 542 Users on board!

Forums menu