/*
Remote Recorder
A script to capture remote log file data using web bugs.
For our privacy policy please refer to our site at www.panalysis.com.au/privacy/
*/
var pURI, pHost, pReferer, pQuery,pAc,pRN,pWebBug,pImgSrc,pRvisit;
var pCID = 'mbtd45ob23'; // you must include a valid pCID supplied by Panalysis
var pStatsHost = "http://secure.panalysis.com/stats/index.php";
var pClientDomain = this.location.hostname;
var pidname = "p_id";
var sidname = "session_id";
var pid = "";
var sid ="";
var pOutBoundURLBase = "/outboundlinks/";
var pParams = "";
var pWebBug;
var pMaxDelays = 500;
var pCDelay = 0;
var pbImgLoaded = 0;
var pPTitle = "";
var pBannerList = new Array();
if ((document.location.protocol).toLowerCase() == "https:" )
pStatsHost = "https://secure.panalysis.com/stats/index.php"
function pSetCookie(cookieName,cookieValue,nDays) {
var today = new Date();
var expire = new Date();
if (nDays==null || nDays==0) nDays=1;
expire.setTime(today.getTime() + 3600000*24*nDays);
document.cookie = cookieName+"="+escape(cookieValue) + ";expires="+expire.toGMTString() + "; path=/; domain=" + pClientDomain;
}
function pReadCookie(cookieName) {
var theCookie=""+document.cookie;
var ind=theCookie.indexOf(cookieName);
if (ind==-1 || cookieName=="") return "";
var ind1=theCookie.indexOf(';',ind);
if (ind1==-1) ind1=theCookie.length;
return unescape(theCookie.substring(ind+cookieName.length+1,ind1));
}
function pTestCookie(){
pSetCookie("accepttest",1,10);
if(pReadCookie("accepttest")) {
return 1;
}else{
return 0;
}
}
function pMakeID(){
var id;
id = Math.random() * 100000000000000000;
return id;
}
function pWriteLink(bIgnoreParams){
pRN =Math.floor(Math.random()*100000)
pImgSrc = pStatsHost + '?cid=' + pCID + '&uristem=' + pURI;
if(pQuery) pImgSrc += '&query=' + pQuery
if(pReferer) pImgSrc += '&referer=' + pReferer
if(pHost) pImgSrc += '&host=' + pHost
pImgSrc += '&ac=' + pAc;
pImgSrc +='&rn=' + pRN;
pImgSrc +='&pid=' + pid;
pImgSrc +='&sid=' + sid;
pImgSrc +='&m=j';
if(bIgnoreParams != true)
{
pImgSrc += '&' + pGetPageParams();
pImgSrc += pParams;
}
if(pRvisit == true)
pImgSrc +='&r=1';
else
pImgSrc +='&r=0';
pWebBug = new Image();
if(pWebBug)
{
pWebBug.src = pImgSrc;
pWebBug.onload = function () { pRetVoid();}
return true;
}
else
{
document.write("
");
return true;
}
}
function trackOutbound(theURL){
var startURL, finalURL, finalQuery;
var s = new String (theURL);
if(s.indexOf('://') > 0)
{
startURL = s.indexOf('://') + 3;
if(s.indexOf('?') > 0)
{
finalURL = s.substring(startURL,s.indexOf('?'));
pURI = pOutBoundURLBase + finalURL;
pQuery = s.substring(s.indexOf('?')+1);
}
else
{
finalURL = s.substring(startURL);
pURI = pOutBoundURLBase + finalURL;
}
}
else
pURI = theURL;
pHost = escape(window.location.hostname);
if ((window.document.referrer!="") && (window.document.referrer!="-") && (window.document.referrer!=undefined)){
if (!(navigator.appName=="Microsoft Internet Explorer" && parseInt(navigator.appVersion)<4)){
pReferer=escape(window.document.referrer);
}
}
return pWriteLink(true);
}
function pTrackBannerView(theBannerName,theBannerFile)
{
pParams = "&p_bn=" + escape(theBannerName);
if(theBannerFile)
pParams += "&p_bf=" + escape(theBannerFile);
pWriteLink();
return true;
}
function pTrackBannerClick(theBannerName)
{
pParams = "&p_bc=" + escape(theBannerName);
return pWriteLink();
return false;
}
function pTrackBannerLanding(theBannerName)
{
pParams = "&p_bl=" + escape(theBannerName);
pWriteLink();
return 1;
}
function pTrackRevenue(theRevVal)
{
pParams = "&p_rev=" + escape(theRevVal);
pWriteLink();
return 1;
}
function pAddBanner(theBannerName)
{
var pIntNumBanners = 0;
if(pBannerList.length>0)
pIntNumBanners = pBannerList.length;
else
pIntNumBanners = 0;
pBannerList[pIntNumBanners] = theBannerName;
}
function pSendBannerViews()
{
if(pBannerList.length>0)
{
pParams = "";
for(var i=0;i1500)
{
pWriteLink();
pParams = "";
}
}
if(pParams != "")
{
pWriteLink();
}
}
return true;
}
function pGetPageParams()
{
var pMetaTags;
var pStrParams;
if (document.title) pStrParams = "p_ti=" + escape(document.title);
if (document.all) pMetaTags=document.all.tags("meta");
else if (document.documentElement) pMetaTags=document.getElementsByTagName("meta");
if (typeof(pMetaTags)!="undefined"){
for (var i=0;i0){
pAc=1;
}else{
pAc=0;
}
if(pAc ==1)
{
// try to see whether the visitor has been before
pid = pReadCookie(pidname);
if(! pid)
{
pid = pMakeID();
pSetCookie(pidname,pid,365);
pRvisit = false;
}
else
pRvisit = true;
sid = pReadCookie(sidname);
if(! sid)
{
var d = new Date();
sid = pid + ":" + d.getTime();
pSetCookie(sidname,sid,1);
}
}
pURI = escape(window.location.pathname);
pQuery = window.location.search;
pQuery = pQuery.substring(1,pQuery.length);
pQuery = escape(pQuery);
pHost = escape(window.location.hostname);
if ((window.document.referrer!="") && (window.document.referrer!="-") && (window.document.referrer!=undefined)){
if (!(navigator.appName=="Microsoft Internet Explorer" && parseInt(navigator.appVersion)<4)){
pReferer=escape(window.document.referrer);
}
}
pWriteLink();