var clicky={init:function(){var a="",o="",ua=navigator.userAgent;if(ua.indexOf('MSIE')!=-1){a="ie";}else if(ua.indexOf('Firefox')!=-1){a="ff";}else if(ua.indexOf('Safari')!=-1){a="s";}else if(ua.indexOf('Opera')!=-1){a="o";}if(ua.indexOf('Windows')!=-1){o="w";}else if(ua.indexOf('Macintosh')!=-1){o="m";}else if(ua.indexOf('Linux')!=-1){o="l";}clicky.img=new Image();clicky.img_base="http://getclicky.com/in.php?site_id= 151057&useragent="+a+"&os="+o+"&r="+Math.random();if(clicky.isset("clicky_custom_session")){for(i in clicky_custom_session){clicky.img_base+="&custom_session"+encodeURIComponent("["+i+"]")+"="+encodeURIComponent(clicky_custom_session[i]);}}clicky.add_event(window,"load",clicky.pageview);},isset:function(x){return(typeof(window[x])!="undefined");},pause:function(){var now=new Date();var stopTime=now.getTime()+1000;while(now.getTime()<stopTime)var now=new Date();},img_src:function(e,type){obj=clicky.get_target(e);var txt=clicky.get_text(obj).substr(0,60);var href=clicky.get_href(obj);if(type=="download")href=href.replace(/^https?:\/\/([^\/]+)/i,"");clicky.img.src=clicky.img_base+"&type="+type+"&title="+encodeURIComponent(txt)+"&pathname="+encodeURIComponent(href);clicky.pause();},download:function(obj){clicky.img_src(obj,"download");},outbound:function(obj){clicky.img_src(obj,"outbound");},get_text:function(e){do{var txt=e.text?e.text:e.innerText;if(txt)return txt;if(e.alt)return e.alt;if(e.title)return e.title;if(e.src)return e.src;e=clicky.get_parent(e);}while(e);return"";},get_href:function(e){do{if(e.href&&!e.src)return e.href;e=clicky.get_parent(e);}while(e);return"";},get_parent:function(obj){return obj.parentElement?obj.parentElement:obj.parentNode;},get_target:function(obj){if(!obj)var obj=window.event;var t=obj.target?obj.target:obj.srcElement;if(t.nodeType&&t.nodeType==3)t=t.parentNode;return t;},add_event:function(obj,event,func){if(obj.addEventListener){obj.addEventListener(event,func,false);}else if(obj.attachEvent){obj.attachEvent("on"+event,func);}},pageview:function(){var lang=navigator.appName=='Netscape'?navigator.language:navigator.browserLanguage;clicky.img.src=clicky.img_base+'&title='+encodeURIComponent(document.title)+'&referer='+encodeURIComponent(document.referrer)+'&pathname='+encodeURIComponent(location.pathname)+'&search='+encodeURIComponent(location.search)+'&res='+screen.width+'x'+screen.height+'&lang='+lang.substr(0,2);clicky.advanced();},advanced:function(){if(clicky.isset("clicky_advanced_disable"))return true;var dtypes=clicky.isset("clicky_download_types")?clicky_download_types:"7z|aac|avi|doc|exe|flv|gif|gz|jpe?g|mp(3|4|e?g)|mov|pdf|phps|png|ppt|rar|sit|tar|torrent|txt|wma|wmv|xls|xml|zip";var ltypes=clicky.isset("clicky_link_types")?clicky_link_types:"https?|ftp|telnet|ssh|ssl|mailto";var is_download=new RegExp("\\.("+dtypes+")$","i");var is_link=new RegExp("^("+ltypes+"):","i");var is_link_internal=new RegExp("^https?:\/\/(.*)?"+location.host,"i");var a=document.getElementsByTagName('a');for(var i=0;i<a.length;i++){if(is_link.test(a[i].href)&&a[i].className.indexOf("clicky_ignore")==-1){if(is_link_internal.test(a[i].href)){if(is_download.test(a[i].href)){clicky.add_event(a[i],"mouseup",clicky.download);}}else{clicky.add_event(a[i],"mouseup",clicky.outbound);}}}}};clicky.init();
