Global.asa .. Session_OnEnd (repost)

Results 1 to 2 of 2

Thread: Global.asa .. Session_OnEnd (repost)

  1. #1
    Join Date
    Dec 1969

    Default Global.asa .. Session_OnEnd (repost)

    I have a user updatable directory database application set up. Users enter an ID & password to log in then can change their information in the database (several pages). <BR><BR>What I would like to accomplish is once a users session has ended that a thank you email be sent to the user. I know how to get the email address out of the dB and how to send an email.<BR><BR>I thought Sessions (specifically Session_OnEnd) might be a good way to solve this. I added Session("emailadr") = email address to send thank you to, once the user sucesfully authenticates.<BR>Then added this to a global.asa in that directory.<BR><BR>&#060;SCRIPT LANGUAGE="VBScript" RUNAT="Server"&#062;<BR>Sub Session_OnStart<BR>&nbsp;&nbsp;&nbsp;Session.Timeo ut = 5<BR>End Sub<BR><BR>Sub Session_OnEnd<BR>&nbsp;&nbsp;&nbsp;Set Mail = Server.CreateObject("Persits.MailSender")<BR>&nbsp ;&nbsp;&nbsp;&#039....Other Mail Code Referencing Session("emailadr")...<BR>End Sub<BR>&#060;/SCRIPT&#062;<BR><BR>I tested the mail code in a std asp page and it works fine, but when a session times out/expires the code in the global.asa does not appear to run.<BR><BR>Any help/assistance anyone could offer would be appreciated.<BR><BR>Thanks,<BR>Desiree

  2. #2
    Join Date
    Dec 1969

    Default RE: Global.asa .. Session_OnEnd (repost)

    Session_OnEnd, for resons never explained, almost never runs when database interaction is involved.

Posting Permissions

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