Page 1 of 1

Has anybody else experiencing that strptime() hangs?

Posted: Sun Sep 20, 2009 9:40 pm
by jeff00seattle
I did the first example for PHP function strptime(): http://us2.php.net/manual/en/function.strptime.php

And everytime I run it, function strptime() hangs. No exceptions thrown, nothing, it just hangs.

Code: Select all

$format = '%d/%m/%Y %H:%M:%S';
$strf = strftime($format);
 
echo "$strf\n";
 
print_r(strptime($strf, $format));
Is anybody else experiencing the same issue? I am running PHP 5.2.9.

Thanks

Jeff in Seattle

Re: Has anybody else experiencing that strptime() hangs?

Posted: Sun Sep 20, 2009 10:22 pm
by Eric!
Try turning on errors.
error_reporting(E_ALL);

I get a fatal error on php 5.2.5, undefined function.

Re: Has anybody else experiencing that strptime() hangs?

Posted: Sun Sep 20, 2009 10:37 pm
by requinix
Eric! wrote:I get a fatal error on php 5.2.5, undefined function.
There's no strptime on Windows.

Re: Has anybody else experiencing that strptime() hangs?

Posted: Sun Sep 20, 2009 10:47 pm
by jeff00seattle
tasairis wrote:There's no strptime on Windows.
I am on Windows XP.
Where did you find this information?
Just curious, is there an alternative for strptime()?

Thanks

Jeff in Seattle

Re: Has anybody else experiencing that strptime() hangs?

Posted: Mon Sep 21, 2009 12:04 am
by requinix
jeff00seattle wrote:I am on Windows XP.
Where did you find this information?
And people wonder why they should read manuals...

http://www.php.net/manual/en/function.strptime.php