Package home | Report new bug | New search | Development Roadmap Status: Open | Feedback | All | Closed Since Version 1.5.0a4

Bug #969 Dates created from a string don't set properties correctly
Submitted: 2004-03-08 05:30 UTC
From: redbeard at mdjohnson dot us Assigned: pajoye
Status: Closed Package: Date
PHP Version: Irrelevant OS:
Roadmaps: (Not assigned)    
Subscription  
Comments Add Comment Add patch


Anyone can comment on a bug. Have a simpler test case? Does it work for you on a different platform? Let us know! Just going to say 'Me too!'? Don't clutter the database with that please !
Your email address:
MUST BE VALID
Solve the problem : 5 - 3 = ?

 
 [2004-03-08 05:30 UTC] redbeard at mdjohnson dot us
Description: ------------ When creating a date from a string, the various properties (year, month, day, etc) are set to strings instead of integers. This results in calls to the access methods (e.g. getDay()) to return strings, which can result in incorrect output. Reproduce code: --------------- $d = new Date('2004-01-01'); echo $d->getDay(); Expected result: ---------------- 1 Actual result: -------------- 01

Comments

 [2004-03-12 11:24 UTC] User who submitted this comment has not confirmed identity
If you submitted this note, check your email.If you do not have a message, click here to re-send
MANUAL CONFIRMATION IS NOT POSSIBLE.  Write a message to pear-dev@lists.php.net
to request the confirmation link.  All bugs/comments/patches associated with this

email address will be deleted within 48 hours if the account request is not confirmed!