[WEB4LIB] date last modified script?
Dennis Moser
dennism at library.tmc.edu
Wed Feb 9 09:54:54 EST 2000
If your server/sysadmins will allow you to use a server-side include, you
won't need to use a script. For example:
<FONT SIZE=1><B>
This document last adjusted on</FONT>
<FONT COLOR='RED'SIZE=1>
<!--#echo var="LAST_MODIFIED" -->
</FONT>
<FONT SIZE="1">by its</FONT><A HREF="mailto:aldus at angrek.com">
<FONT SIZE="1"> Webmaster</FONT><BR>
...yields this:
"This document last adjusted on Monday, 13-Apr-1998 08:05:24 EDT by its
Webmaster"
(with the appropriately colored text attributes; what can I say, the page
hasn't needed to be changed in a while). Note that most of the code is to
describe the text; the actual SSI snippet is a single line ("<!--#echo
var="LAST_MODIFIED" -->")...and the call is a system call, so as long as you
are allowed to do this and using "*.shtml" won't cause too many headaches in
making the change, this is a pretty simple way to do it.
Dennis Moser, MILS, Web Librarian
John P. McGovern Historical Collections and Research Center
Houston Academy of Medicine-Texas Medical Center Library
1133 M. D. Anderson Blvd, Houston, TX 77030-2809
dennism at library.tmc.edu
-----Original Message-----
From: Mariner, Vincent A. <vmariner at fgcu.edu>
To: Multiple recipients of list <web4lib at webjunction.org>
Date: Wednesday, February 09, 2000 7:47 AM
Subject: [WEB4LIB] date last modified script?
>Hello folks,
>
>Can anyone point me to a date last modified script? The one I currently
>use is not working correctly in Netscape Communicator.
>
>Here's the current scipt:
>
> <SCRIPT TYPE="text/javascript"> var theDate = ""
> theDate = document.lastModified
> document.writeln("Last Updated: ");
> document.write(theDate);
> document.write();
> </SCRIPT>
>
>and here is what it produces in Netscape Communicator:
>
>Last Updated: Wednesday, December 31, 1969 20:00:00
>
>Works just fine in I.E. 5
>
>As I looked for a script, I noticed that many people are not using scripts
>for this purpose. Is this more appropriate, common, a trend, etc.?
>
>Thanks,
>Vince
>
More information about the Web4lib
mailing list