Page is a not externally linkable
- Marketing and Biz Dev
-- General Search Engine Marketing Issues
---- SEO: Closed-loop ROI tracking


RaraAvis - 9:09 pm on Jul 12, 2002 (gmt 0)


Frost,

There are a bunch of different ways to do what you're talking about. I'm *sure* there is software/freeware/open source code you can use but we have never researched it. The way *we* do it on *some* of our sites is this (there are much more complex tracking methods as well that can tell you w/ a Session ID writing to a cookie how many times a user has visited a site before contact/sale):

THIS ASP CODE SETS THE COOKIE. IT MUST GO ABOVE EVERY OTHER LINE OF CODE ON YOUR PAGE - ABOVE THE <HEAD> TAG. Change "SITENAME" to your site name (something totally unique).

<%
if request.cookies("SITENAME")="" then
vRef = Request.ServerVariables("HTTP_REFERER")
response.cookies("SITENAME")("Referer") = vRef
response.cookies("SITENAME").expires = now + 720
end if
%>

ON YOUR EMAIL FORM OR SHOPPING CART FORM YOU NEED TO CAPTURE THE REFERRER FROM THE COOKIE AND PUT IT IN A HIDDEN FIELD:

<input type="hidden" name="Referer" value="<%=Server.HTMLEncode(request.cookies("SITENAME")("Referer"))%>">

WHEN USING AN ASP SENDMAIL FORM LIKE WE USE, YOU SIMPLY REQUEST THE 'REFERRER' AS YOU WOULD ANY OTHER FIELD FROM THE FORM.

vReferer = request.form("Referer")

WE HAVE THE FORM SEND TWO SEPARATE EMAILS, ONE W/ ALL INFO *EXCEPT* THE REFERRER TO THE CLIENT AND ONE TO US W/O PERSONAL INFO AND *WITH* THE REFERRER.

I hope this helps!


Thread source:: http://www.webmasterworld.com/search_engine_promotion/1204.htm
Brought to you by WebmasterWorld: http://www.webmasterworld.com