note 46613 added to function.getlastmod
| From: | rwruck at osu1 dot php dot net | Date: | Sun, 17 Oct 2004 13:28:42 +0000 |
| Subject: | note 46613 added to function.getlastmod | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-78695@lists.php.net to get a copy of this message | ||
DO NOT use this function unless you are absolutely sure both your Apache and PHP have been compiled
with the same value for -DFILE_OFFSET_BITS.
If not, this function will return the access time (or maybe even garbage) instead of the
modification time due do Apache and PHP using different versions of the stat structure.
This is true regardless of Apache and PHP version.
To be on the safe side, always use the workaround already posted below:
filemtime($_SERVER['SCRIPT_FILENAME'])
----
Manual Page -- http://www.php.net/manual/en/function.getlastmod.php
Edit -- http://master.php.net/manage/user-notes.php?action=edit+46613
Delete -- http://master.php.net/manage/user-notes.php?action=delete+46613&report=yes
Reason: bad code -- http://master.php.net/manage/user-notes.php?action=delete+46613&report=yes&reason=bad+code
Reason: spam -- http://master.php.net/manage/user-notes.php?action=delete+46613&report=yes&reason=spam
Reason: useless example -- http://master.php.net/manage/user-notes.php?action=delete+46613&report=yes&reason=useless+example
Reason: contains commercial links -- http://master.php.net/manage/user-notes.php?action=delete+46613&report=yes&reason=contains+commercial+links
Reason: useless note -- http://master.php.net/manage/user-notes.php?action=delete+46613&report=yes&reason=useless+note
Reject -- http://master.php.net/manage/user-notes.php?action=reject+46613&report=yes
Search -- http://master.php.net/manage/user-notes.php