| Added: December/19/2008 at 3:42pm | IP Logged
|
|
|
Hello all,
I've developed sort of a hack for addressing this issue.
Summary: Using IP tracking, if you visit your site, you will see a generic banner of your choosing. This, obviously, won't get tracked. If you making a request that's not from your IP, or you enable a cookie by clicking that generic banner, you will see the "Real" banners until your session is closed out.
First create a page called "banners_enabled.asp" that includes the code
<% 'set the cookie for showing the banners Response.Cookies("Banners") = "True" Response.Cookies("Banners").Path = "/" Response.Redirect("default.asp") %>
Then on the page where you call your banners but this code around CW's banner calling code...
<% dim strBannersEnabled%> <% strBannersEnabled = Request.Cookies("Banners") %> <% if (Request.ServerVariables("REMOTE_ADDR") = "IP.ADDRESS.NO.1" or Request.ServerVariables("REMOTE_ADDR") = "192.168.1.100") and strBannersEnabled <> "True" then %> <% 'this is a office ip, don't track clicks or impressions!! Just show a generic banner(also added local IP for dev testing) %> <a HREF=http://www.yourwebsite.com/banner_enable.asp> <img alt="Click this banner to turn on real banners" border="0" src="http://www.yourwebsite.com/generic_480x60.bmp"></a> <% else %> <!------- ASPBanner Ad code -------------> <script language="JavaScript"> var code = ''; var now = new Date(); var nIndex = now.getTime(); document.write('<s' + 'cript src=" http://www.yourwebsite.com/aspbanner/injectbanner.asp?Banner Zone=1&nocache=' + nIndex + '">'); document.write('</' + 's' + 'cript>'); </script> <script language="JavaScript">document.write(jscode);</script& gt; <!--------- End ASPBanner Ad code ---------------> <% end if %>
That's about it, really. This isn't meant to be a step-by-step but its a solution to keep you from capturing your clicks. You can add any number of ip addresses or server names as your situation merits.
|