The principle is this:
- Register an
unloadevent which posts the information as XML with AJAX to a script on the server when the user leaves the page.
- Browsing sessions can be collated on the server using cookies.
- Create a player, which reads the events as XML and renders them using a DHTML 'cursor' and/or by firing events within the DOM. Could have a time slider and fast-forward controls, etc, depending on how complex you want to get.
Voila - see exactly what people are doing with your site. I have knocked up a test which implements the first two steps, for
window.confirm() dialog asking if it's OK to record your behaviour. But it would be a very useful tool for examining site usage, especially for commercial sites. This is the way modern marketing works. I leave it up to your conscience as to whether it's ethical.