|
 |
asp_web_howto thread: how do i retreive the time spent on a page to store it as a statistic element in the database
Message #1 by eric@a... on Fri, 13 Sep 2002 12:44:46
|
|
i want to know how many time someone spents looking ( reading?) a page...
anyone an idea to track this time...probably something like tracking the
time a user leaves the page?
Message #2 by "Scott Dempsey" <scottd@c...> on Fri, 13 Sep 2002 08:39:29 -0700
|
|
I did something similar awhile ago. It's a little tricky (and not asp).
Use the onload feature to instantiate a JS function that stores the page
visit time as a cookie on the clients machine. Then use the onUnload
feature to instantiate a second JS function that will extract that
value, compare it to the current time, and there is you have it.
(That's what I did, works great)
- Scott
-----Original Message-----
From: eric@a... [mailto:eric@a...]
Sent: Friday, September 13, 2002 12:45 PM
To: ASP Web HowTo
Subject: [asp_web_howto] how do i retreive the time spent on a page to
store it as a statistic element in the database
i want to know how many time someone spents looking ( reading?) a
page...
anyone an idea to track this time...probably something like tracking the
time a user leaves the page?
---
Improve your web design skills with these new books from Glasshaus.
Usable Web Menus
http://www.amazon.com/exec/obidos/ASIN/1904151027/ref=nosim/theprogramme
r-20
Constructing Accessible Web Sites
http://www.amazon.com/exec/obidos/ASIN/1904151000/ref=nosim/theprogramme
r-20
Practical JavaScript for the Usable Web
http://www.amazon.com/exec/obidos/ASIN/1904151051/ref=nosim/theprogramme
r-20
Message #3 by "TomMallard" <mallard@s...> on Sun, 15 Sep 2002 07:57:33 -0700
|
|
Did this a couple of times using the onunload() event to store times on the
client using cookies. The next request by that client has the cookies for
the server to evaluate of the last viewed page times.
This was pretty easy to do...worked very well to get stats on user habits.
If you can't use cookies, you'll need a component they'll have to download
to do it.
tom mallard
seattle
-----Original Message-----
From: eric@a... [mailto:eric@a...]
Sent: Friday, September 13, 2002 12:45 PM
To: ASP Web HowTo
Subject: [asp_web_howto] how do i retreive the time spent on a page to
store it as a statistic element in the database
i want to know how many time someone spents looking ( reading?) a page...
anyone an idea to track this time...probably something like tracking the
time a user leaves the page?
---
Improve your web design skills with these new books from Glasshaus.
Usable Web Menus
http://www.amazon.com/exec/obidos/ASIN/1904151027/ref=nosim/theprogramme
r-20
Constructing Accessible Web Sites
http://www.amazon.com/exec/obidos/ASIN/1904151000/ref=nosim/theprogramme
r-20
Practical JavaScript for the Usable Web
http://www.amazon.com/exec/obidos/ASIN/1904151051/ref=nosim/theprogramme
r-20
|
|
 |