|
Posted by JackM on 01/11/07 00:48
JackM wrote:
> NC wrote:
>
>>> Is there a way to use PHP to read the date of a file that is uploaded
>>> into a directory and then print out that date on another page?
>>
>>
>> Yes:
>>
>> echo date('F, n, Y', filemtime('/texts/filename.pdf'));
>
>
> Everything is coming up with a December 12, 1969 date when I use this.
> Any idea why?
Found out why. I had to go up one more level to read the file:
filemtime('./texts/filename.pdf')
But the strange thing is that the file dates are all coming out January
1, 2007 now even when the files were created and/or modified after that
date.
--
My email address on the header is a non-monitored spam catching account.
I can be reached via http://www.wvnh.net/contact.htm
The dates for the next RADP meet (RADP-XII) are October 12-15, 2007,
followed by the 2007 Holiday Meets on December 7-10, 2007.
Navigation:
[Reply to this message]
|