In the times of pure and simple HTML you could look at a page's
metadata, e.g. with right click "View Page Info" and get (among other
stuff) "Modified: 4 July 2008 14:40:03". Often very useful information
IMHO. The function still exists, but nowadays what you get usually is
the very minute you called that page up - useless.
That need not be so. There are several reasons for the "modified" entry
no longer to work:
Add the following at the very top, before the <!Doctype:
$mtime = filemtime($_SERVER['SCRIPT_FILENAME']);
$last_modified = gmdate('D, d M Y H:i:s', $mtime) . ' GMT';
Add this to your .htaccess:
3) CMSs and blogging software:
Not easy. You have to rely on what your system offers, if anything. But
at least good templates contain a "posted" date somewhere in the layout,
giving some indication of age.
If you use fancy layouts with footers or similar, it is also a good idea
to include the file date in there.
4) When adding the footer through SSI the code may be:
<!--#config timefmt="%Y-%m-%d" -->
Last modified: <!--#echo var="LAST_MODIFIED" -->
Note that this will display the date of the main file, not that of the
generic footer, which is exactly what you want here.
All those fancy new designer additions tend to make us lose what was
best and most powerful about the web. Let us fight back and retain
what's ours by right.
Dipl.-Ing. F. Axel Berger Tel: +49/ 2174/ 7439 07
Johann-Häck-Str. 14 Fax: +49/ 2174/ 7439 68
D-51519 Odenthal-Heide eMail: Axel-Berger@...
Deutschland (Germany) http://berger-odenthal.de