Home » Logging » Log » Bug #7629
strftime(%T) does not work under MS Windows 2000
Details
| Submitted | 2006-05-15 16:37 UTC |
|---|---|
| From | suttner at anduras dot de |
| Assigned | jon |
| Status | Closed |
| Package | Log |
| PHP Version | 5.1.2 |
| OS | MS Windows 2000 |
| Roadmaps | (Not assigned) |
Comments
[2006-05-15 16:37 UTC] suttner at anduras dot de
Description:
------------
The funtion strftime (%T) does not work on some operation systems.
PHP Documentation:
This means that e.g. %e, %T, %R and %D (there might be more)
and dates prior to Jan 1, 1970 will not work on Windows,
some Linux distributions, and a few other operating systems.
http://de3.php.net/manual/en/function.strftime.php
We have changed the code to
$line = '<tr align="left" valign="top">';
$line .= sprintf('<td>%s.%s</td>',
strftime('%H:%M:%S', $sec), substr($usec, 2, 2));
This does work on windows 2000, too.
[2006-05-26 18:16 UTC] anthony dot settergren at gmail dot com
Instead of %S just use %H:%M:%S. It gives the same thing. This works for windows 2000.