Filemtime/cachetime where am I going wrong?
What I am trying to do is check the age of an image, if its older than 60 minutes then run another php page to fetch images otherwise do nothing if less than 60 minutes old....

The script works as in running the other page, but does it all the time instead of using the timer. I have placed this in the head of the page.

    <?php
    $imagename='./radar/auck0.png';
    $cachetime = 3600;
        //Start the caching of the images........
        if (file_exists($imagename) and filemtime($imagename) + $cachetime > time()) {
              echo("radartest.php");
            } else {
      null; //do nothing
    }
    ?>
Filemtime/cachetime where am I going wrong?
===

What I am trying to do is check the age of an image, if its older than 60 minutes then run another php page to fetch images otherwise do nothing if less than 60 minutes old....

The script works as in running the other page, but does it all the time instead of using the timer. I have placed this in the head of the page.

    <?php
    $imagename='./radar/auck0.png';
    $cachetime = 3600;
        //Start the caching of the images........
        if (file_exists($imagename) and filemtime($imagename) + $cachetime > time()) {
              echo("radartest.php");
            } else {
      null; //do nothing
    }
    ?>