pages with a message such as: "This page last updated on March 18,
1995". I want it to be honest, telling the save-date of the jsp file, the date when I actually last edited the file.
I hoped that I would achieve this by using the code below, which I think should capture the date when the servlet was compiled, which I thought would be close enough to the date when I most recently saved the file. But it looks like the servlet gets recompiled every time I restart Tomcat, or, to be more specific, the date which this shows is the first date after Tomcat has been restarted on which the page is accessed.
So, I'm looking for suggestions. How can I automate the honest updating of my "page updated" reports?
Thank you, Rich Hammer Hillsborough, N.C.
Near the bottoms of my JSPs I am using this line: <[EMAIL PROTECTED] file="updateReport.jsp" %>
And here is that file, updateReport.jsp:
<%@ page import="java.text.DateFormat,java.util.Date" %>
<%!
static DateFormat dateFormat =
DateFormat.getDateInstance(DateFormat.LONG);
static String compileDate = dateFormat.format(new Date());
%>
<center
style= "font-size: smaller; font-family: sans-serif;
font-style: italic; text-align: center;"
>
This page last updated on <%= compileDate %>
</center>
_______________________________________________ Juglist mailing list [EMAIL PROTECTED] http://trijug.org/mailman/listinfo/juglist_trijug.org
