Re: showing last mod. of *included* file

From: Date: Sat, 02 Mar 2002 03:12:56 +0000
Subject: Re: showing last mod. of *included* file
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-86879@lists.php.net to get a copy of this message
On Saturday 02 March 2002 07:05, Timothy J. Luoma wrote: > I have been using this code to show the last modified time: > > > // 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 [snip] > 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? Use filemtime(). -- Jason Wong -> Gremlins Associates -> www.gremlins.com.hk /* Your mode of life will be changed for the better because of new developments. */

« previous php.general (#86879) next »