&http-last-modified; (crazy idea of the day)

Daniel W. Connolly (connolly@beach.w3.org)
Fri, 15 Dec 1995 15:07:15 -0500

Just a hair-brained idea that I don't want to forget:


200 document follows:
Last-Modified: Monday, 11-Dec-95 22:04:31 GMT

<title>Dan's Hair-brained Idea of the Day</title>


displays ala:

Dan's Hair-brained Idea of the Day


Monday, 11-Dec-95 22:04:31 GMT

Other possibilities:

200 document follows
Access-Count: 12312
Access-Count-Since: Monday, 11-Dec-95 22:04:31 GMT

This page has been accessed &http-access-count; times
since &http-access-count-since;.

It's a nifty idea that would save a lot of trouble and automate a lot
of stuff that folks do, and increse cache effectiveness. Access count
would require support from servers, but for example, it should be a
pretty straightforward Apache module:

(1) add a config directive that listst the documents/directories
where you want to keep access counts.
(2) keep a DBM database that maps document->count
(3) add the Access-Count header for documents in the dbm database.

It ought to take about an hour to hack up client support. Any takers?
I started adding support to grail (see http://www.python.org/ and
search for grail) but I'm having trouble getting at the http headers
from inside the parser. I think I need to pass them from the Reader
object to the Viewer object, and then have the Parser object ask the
viewer. Hmmm... I wonder how this interacts with caching.