Getting the session referral source URL

Topics: Business Logic Layer
Sep 19, 2013 at 4:40 PM
Quick question;

Are there any functions in BE that would give me the referring site for the current visitor session. I currently send a notification email out when a visitor requests more info and would like to add to it information about where the user came from ... i.e: HTTP_REFERER.

Since this would need to be captured when the session is initiated, I'm hoping that BE has some code already doing that?

thanks in advance
Sep 19, 2013 at 5:45 PM
I'm looking in the Global.asax (where application/session start events are triggered) and not seeing anything specific. But you could probably add something to Application_BeginRequest like "If (HTTP_REFERRER <> "") { session.add(HTTP_REFERRER,"Referrer"); }". Note that's off the top of my head and not real code. In your email building routine you could then retrieve session("Referrer") if it's interactive.