note 60951 added to function.filemtime
| From: | nicoolai at hotmail dot com | Date: | Fri, 20 Jan 2006 23:53:02 +0000 |
| Subject: | note 60951 added to function.filemtime | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-102189@lists.php.net to get a copy of this message | ||
I tried to use the elseif to report the "last updated" with filemtime. It will not
display...why?
<?php
$index = filemtime("index.php");
$competence = filemtime("competence.php");
$solutions = filemtime("solutions.php");
$contact = filemtime("contact.php");
$var1 = array("$competence","$solutions,"$kontakt");
$var2 = array("$index","$solutions","$contact");
$var3 = array("$index","$competence","$contact");
$var4 = array("$index","$competence","$solutions");
if ($index >= $var1) {
$result = "Last updated: " . date("j. F Y \-\ \k\l\.\ G:i", $index);
} elseif ($competence >= $var2) {
$result = "Last updated: " . date("j. F Y \-\ \k\l\.\ G:i", $competence);
} elseif ($losninger >= $var3) {
$result = "Last updated: " . date("j. F Y \-\ \k\l\.\ G:i", $solutions);
} elseif ($contact >= $var4) {
$result = "Last updated: " . date("j. F Y \-\ \k\l\.\ G:i", $contact);
}
echo "$result";
?>
----
Server IP: 194.239.128.8
Probable Submitter: 80.198.147.158
----
Manual Page -- http://www.php.net/manual/en/function.filemtime.php
Edit -- http://master.php.net/manage/user-notes.php?action=edit+60951
Delete: added to the manual -- http://master.php.net/manage/user-notes.php?action=delete+60951&report=yes&reason=added+to+the+manual
Delete: bad code -- http://master.php.net/manage/user-notes.php?action=delete+60951&report=yes&reason=bad+code
Delete: spam -- http://master.php.net/manage/user-notes.php?action=delete+60951&report=yes&reason=spam
Delete: useless -- http://master.php.net/manage/user-notes.php?action=delete+60951&report=yes&reason=useless
Delete: non-english -- http://master.php.net/manage/user-notes.php?action=delete+60951&report=yes&reason=non-english
Delete: already in docs -- http://master.php.net/manage/user-notes.php?action=delete+60951&report=yes&reason=already+in+docs
Delete: other reasons -- http://master.php.net/manage/user-notes.php?action=delete+60951&report=yes
Reject -- http://master.php.net/manage/user-notes.php?action=reject+60951&report=yes
Search -- http://master.php.net/manage/user-notes.php