Re: Problem with last modified dates...
| From: | Zak Greant | Date: | Wed, 21 Jun 2000 01:47:23 +0000 |
| Subject: | Re: Problem with last modified dates... | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-2425@lists.php.net to get a copy of this message | ||
At 10:52 AM 6/21/00 +0930, David Robley wrote:
On 20 Jun, Jay Paulson wrote: Hello everyone-- Our company's intranet site has an error in the footer PHP code that causes the Last modified date to show up as 1 January 1970, 12:00am GMT. The file is included in nearly all of the 40-50 files in the site, which means the files are all having the problem! The person who wrote the code parsed out the URL to make all parts of the path clickable and then used that parsed path as the path to the file. This works most of the time, but the problem occurs when * The URL is only to the directory (ex. http://intranet.viatel.com/) * The URL has get parameters (ex. http://intranet.viatel.com/index.php3?t=42) I've never run into this problem so any help would be great! Thanks, Jay You could try building the filename for getting the timestamp using DOCUMENT_ROOT and PHP_SELF - this should give you a valid filename that you can feed to filemtime()Hello All, You can also use $SCRIPT_FILENAME to get the complete path to the script. HTH, Zak Greant Creative Director Nucleus Information Service Inc. "A camel is a horse designed by a committee." - Alex Issigonis (Designer of the Morris Mini)