I have been using this code to show the last modified time:

(Note: the following was adapted from http://www.terrabyte.dc.com.au/phpscripts.php3 )

// the server is 13 hours ahead of Eastern Time USA
$hourdiff = "13";
$timeadjust = ($hourdiff * 60 * 60);
$eastern_time = date("d M Y g:ia",getlastmod() - $timeadjust);
echo "Last modified: $eastern_time (ET/USA) <br />";


This works really well, except for one thing.

All of my pages have two required parts:

        index.php
        body.html

and two optional parts

        header.html
        footer.html

The code above is 'include'd into 'index.php'

'index.php' is a boilerplate, and will hardly ever change.

The optional files are not likely to change all that often, if ever, if
they exist.


Is there a way that I can adapt the above PHP code to show the last mod.
time of 'body.html' (always the same filename) instead of index.php?

TjL

ps -- I did try to Google the solution, but this is such a specific
situation (needing to adjust the timestamp and then check the last mod of
an included file) that I did not have any luck finding anything that was
'on target'.  Pointers happily selected.

-- 
TjL, PHP Neophyte
Site: www.tntluoma.com                       mailto:[EMAIL PROTECTED]
Info: Apache/1.3.19 (Unix) with PHP/4.0.6


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to