You are here: Re: Question from php cookbook « PHP Programming Language « IT news, forums, messages
Re: Question from php cookbook

Posted by Philip Ronan on 11/16/37 11:34

"Mike" wrote:

> This is a little snippet from the calendar recipe 3.17. I dont understand
> what the $yesterday and $day_secs are for?

> $yesterday = time() - 86400;

time() is the current time in seconds. If you subtract 86400 from that, you
get the same time on the previous day (Hint: 86400 = 24 x 3600)

> $day_secs = mktime(0, 0, 0, $month, $day, $year);

Uhm, you *are* aware that the PHP documentation is all available online,
aren't you? If you visit <http://php.net/mktime> and read what's there, then
it should become fairly obvious what this means.

--
phil [dot] ronan @ virgin [dot] net
http://vzone.virgin.net/phil.ronan/

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация