ID:               28209
 Updated by:       [EMAIL PROTECTED]
 Reported By:      gamin at centras dot lt
 Status:           Assigned
 Bug Type:         Date/time related
 Operating System: WinXP HE SP1
 PHP Version:      5.0.0RC2
 Assigned To:      derick
 New Comment:

That's feasible for the rewrite, but for the current parser.


Previous Comments:
------------------------------------------------------------------------

[2004-05-19 12:10:35] wb at pro-net dot co dot uk

Just thought that i would point out that in PHP 4 now is real now and
not GNU now so form a BC point of view i think now should be real now.

------------------------------------------------------------------------

[2004-05-19 12:10:17] wb at pro-net dot co dot uk

Just thought that i would point out that in PHP 4 now is real now and
not GNU now so form a BC point of view i think now should be real now.

------------------------------------------------------------------------

[2004-05-19 12:04:25] wb at pro-net dot co dot uk

Hi derick,

    Yes that is strange, What about adding an optional parameter to the
function to set toggle between real now and gnu now?

    Something like:

        int strtotime ( string time [, int now] [, bool gnu = false])

------------------------------------------------------------------------

[2004-05-18 21:53:44] [EMAIL PROTECTED]

This is actually expected behavior because we follow the GNU guidelines
here, but I agree it's a weird thing to do. If nobody objects I'll make
"now" be really now during the rewrite of the strtotime() rewrite.

------------------------------------------------------------------------

[2004-05-18 12:28:09] wb at pro-net dot co dot uk

Im seeing the same thing on FreeBSD 5 with PHP5 rc2.

code: 

<?php
$strtime = strtotime('now');
printf('
     Now:  %11s  %s
Str time:  %11s  %s

'
, time()
, date('d M Y @ H:i:s ')
, $strtime
, date('d M Y @ H:i:s ', $strtime)
);
?>

Expected:


     Now:   1084875653  18 May 2004 @ 11:20:53
Str time:   1084875653  18 May 2004 @ 11:20:53


Actual:


     Now:   1084875653  18 May 2004 @ 11:20:53
Str time:   1084834800  18 May 2004 @ 00:00:00

------------------------------------------------------------------------

The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
    http://bugs.php.net/28209

-- 
Edit this bug report at http://bugs.php.net/?id=28209&edit=1

Reply via email to