Help me get it please?

Results 1 to 8 of 8

Thread: Help me get it please?

  1. #1
    Rachel Anne Guest

    Default Help me get it please?

    here is my question...<BR>if some one is on a page, and on that page is a counter clock counting how long they are on that page, and they either close by using the little x button or they lost the connection...how do I write to a database(access) if the person isnt on the site any longer?<BR>Please help me?<BR>Thanks in advance!<BR>Rachel Anne

  2. #2
    Keith Fowler Guest

    Default RE: Help me get it please?

    Keep your clock counter in a session variable. You can then insert it into your DB during the Session_On_End event.

  3. #3
    Rachel Anne Guest

    Default RE: Help me get it please?

    How do you do that?

  4. #4
    Jairo Guest

    Default RE: Help me get it please?

    The Session_On_End event can be accessed in your global.asa file.<BR>Open it up, and add your database insert code there.<BR><BR>HTH,<BR>Jairo<BR>


  5. #5
    Rachel Anne Guest

    Default RE: Help me get it please?

    I am still Lost......HELP!

  6. #6
    Join Date
    Dec 1969
    Posts
    1,671

    Default RE: Help me get it please?

    I am assuming you are using a Java Script counter on the client side (since you can&#039t have a "counter" in ASP running on the server.) You can&#039t use that information, since they would have to click a form button to submit it, and you want to save when they just close the browser<BR><BR>You need a table with ID, StartTime, EndTime fields.<BR><BR>You can use Session Variables to log the start and end times of a web Session. In the glabal.asa file, just add a funcion to save the session ID and results of the NOW function in the database. Do this in the session_onStart subroutine. Then just save the save the same thing in the onEnd sub.<BR><BR>This is very general, since I HATE session variables. The real easy way is just get something like WebTrends and install it :)

  7. #7
    Rachel Anne Guest

    Default RE: Help me get it please?

    what is web trends and where can I get it?

  8. #8
    anonymous Guest

    Default RE: Help me get it please?

    Test

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •