note 47810 added to function.mktime

From: Date: Wed, 01 Dec 2004 10:19:50 +0000
Subject: note 47810 added to function.mktime
Groups: php.notes 
Request: Send a blank email to php-notes+get-81216@lists.php.net to get a copy of this message
<?php // Calculates UNIX timestamps from datestamps counting // days from 01/01/0000. Used in some DataFlex databases. // Tested only with Timestamps > 01/01/1970 and // < 31/12/2025. // Arguments: $days (Integer, days-from-0000, // e.g. 731168 = 30/10/2001) function date_diff_value($days) { // 1/1/1970 = 719543 days counting from 01/01/0000 $day_1_1_1970 = 719543; $diff = $days - $day_1_1_1970; $unix_ts = $diff * 86400; return $unix_ts; } ?> ---- Manual Page -- http://www.php.net/manual/en/function.mktime.php Edit -- http://master.php.net/manage/user-notes.php?action=edit+47810 Delete -- http://master.php.net/manage/user-notes.php?action=delete+47810&report=yes Reason: bad code -- http://master.php.net/manage/user-notes.php?action=delete+47810&report=yes&reason=bad+code Reason: spam -- http://master.php.net/manage/user-notes.php?action=delete+47810&report=yes&reason=spam Reason: useless example -- http://master.php.net/manage/user-notes.php?action=delete+47810&report=yes&reason=useless+example Reason: contains commercial links -- http://master.php.net/manage/user-notes.php?action=delete+47810&report=yes&reason=contains+commercial+links Reason: useless note -- http://master.php.net/manage/user-notes.php?action=delete+47810&report=yes&reason=useless+note Reject -- http://master.php.net/manage/user-notes.php?action=reject+47810&report=yes Search -- http://master.php.net/manage/user-notes.php

« previous php.notes (#81216) next »