Re: Date Manipulation

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This code:

echo strtotime("now");
echo mktime("Ymd", strtotime("now"));

is producing this result:

1101945775
Warning: mktime(): Windows does not support negative values for this 
function ...
 -1

What am I doing wrong?

Thanks again.

"John Holmes" <holmes072000@xxxxxxxxxxx> wrote in message 
news:41AD2DB7.4040501@xxxxxxxxxxxxxx
> Christopher Weaver wrote:
>> I've looked at the date functions in the manual but can't find what I 
>> need. All I want to do is add and subtract days without ending up with 
>> bogus date values.  IOW, Nov. 29 + 7 days shouldn't be Nov. 36.
>>
>> Just a nod in the write direction would be great.
>
> mktime() or strtotime()
>
> -- 
>
> ---John Holmes...
>
> Amazon Wishlist: www.amazon.com/o/registry/3BEXC84AB3A5E/
>
> php|architect: The Magazine for PHP Professionals ? www.phparch.com 

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux