Application last modified date

Our web development team has a requirement that we include a date the site was last updated. Since we primarily develop three tier web applications and not static web pages our html pages don't change much as they are views for database data. Instead of a date on each page giving when it was last updated like this article shows how to do, our date shows when the last update was made to the entire application. To do this, I created a cfc function that uses cfdirectory to look at all the files in my application folder on the web server and get the last modified date.

Then I call this function in application.cfc's onSessionStart and store the result in a session variable:

Then to display the result I put the following in my site's footer.

No comments :

Post a Comment

Stay Connected

Subscribe to feed Get email updates Follow @linecomments on Twitter Facebook