Информация. Прошло/осталось дней



Кол-во прошедших дней после…

<?php
$day
= 01;
$month = 01;
$year = 2000;
$age= ((int)((mktime (0,0,0,$month,$day,$year) - time(void))/86400) * -1 );
print (
"Кол-во дней прошедших после 1 января 2000 года: " . $age . ".");
?>

Кол-во дней оставшихся до…

<?php
$day
= 01;
$month = 01;
$year = 2010;
$age= ((int)((mktime (0,0,0,$month,$day,$year) - time(void))/86400) * 1 );
print (
"Кол-во дней оставшихся до 1 января 2000 года: " . $age . ".");
?>

Comments

Post new comment

The content of this field is kept private and will not be shown publicly.
Image CAPTCHA
Copy the characters (respecting upper/lower case) from the image.