note 69363 deleted from function.filemtime by colder
| From: | colder@php.net | Date: | Sat, 02 Sep 2006 12:36:10 +0000 |
| Subject: | note 69363 deleted from function.filemtime by colder | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-116625@lists.php.net to get a copy of this message | ||
Note Submitter: rzrobecki AT gmail.com
Reason: bad code
----
@Benan Tumkaya
if you compare $last_modified with $comparedate, you should strtotime($last_modified), because you
did the same with $comparedate before. So the last part of your script should look like this:
<?
$last_modified = filemtime($fulldir);
$last_modified_str= date("Y-m-d h:i:s", $last_modified);
$last_modified_str2 = strtotime($last_modified_str);
if($comparedate < $last_modified_str2) {
echo $fulldir.'=>'.$last_modified_str;
echo "<BR>";
}
?>