apeisa Posted March 21, 2012 Share Posted March 21, 2012 Currently datetime can only be used for dates which has unix timestamp 0 or above. I noticed this when tried to use datetime field as birthday-field. I guess this would be pretty easy fix to allow pre-1970 dates also? Using signed integer field on database and allow negative values to be saved. 2 Link to comment Share on other sites More sharing options...
ryan Posted March 21, 2012 Share Posted March 21, 2012 Updated to support negative values in the timestamp, and committed. It had to do with validation rather than the DB field type. We're using a MySQL datetime field for storage, so that isn't bound to the limits of timestamps. We're using timestamps just on the PHP side for sortability, sanitization and abstraction from a defined date format. 2 Link to comment Share on other sites More sharing options...
apeisa Posted March 21, 2012 Author Share Posted March 21, 2012 Great stuff, thanks Ryan! Link to comment Share on other sites More sharing options...
bfncs Posted April 5, 2014 Share Posted April 5, 2014 I just stumbled over this as well, thanks a lot for fixing it already, Ryan. Just one question: I was looking for the commit that fixes this but couldn't find it on Github. Can anyone find it? Link to comment Share on other sites More sharing options...
Joss Posted April 5, 2014 Share Posted April 5, 2014 Yep, and a special thanks from all of us YOU who were born before 1970 ..... *cough* Link to comment Share on other sites More sharing options...
Soma Posted April 5, 2014 Share Posted April 5, 2014 I'm out. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now