
OAS_url ='http://austria1.adverserve.net/RealMedia/ads/';
OAS_query = '';
OAS_version = 10;
OAS_rn = '001234567890';
OAS_rns = '1234567890';
OAS_rn = new String (Math.random());
OAS_rns = OAS_rn.substring (2, 11);

var OEWA;
var SITESTAT;
var voted = new Array();

function getPixel(op, st) {
  op = op.replace(/ /g,"_");
  op = op.replace(/:/g,"");
  st = st.replace(/ /g,"_");
  st = st.replace(/\//g,".");
  st = st.replace(/:/g,"");
  
  OEWA = 'http://sportat.oewabox.at/cgi-bin/ivw/CP/'+op;
  document.write('<img name="ivwpic1" src="'+OEWA+'?r='+escape(document.referrer)+'&d='+(new Date()).getTime()+'" width="1" height="1">');
  
  SITESTAT = 'http://de.sitestat.com/laola1/ba-sport/s?'+st;
  sitestat(SITESTAT);
  
  return true;
}

function countivw() {
  
  // oewa
       var img1 = new Image();
	if(window.document.images.ivwpic1) {
		var oewaSrc = window.document.images.ivwpic1.src;
		oewaSrc = oewaSrc.substring (0, oewaSrc.indexOf('&d=')+3) + (new Date()).getTime();
		img1.src = oewaSrc;
	}
  // var img1 = new Image();
  // if(window.document.images.ivwpic1) img1.src = window.document.images.ivwpic1.src;
  
  
  var img3 = new Image();
  if(window.document.images.ns_1) img3.src = window.document.images.ns_1.src;
}

function OAS_NORMAL(pos) { 
  document.write('<a href="'+OAS_url+'click_nx.ads/'+OAS_sitepage+'/1'+OAS_rns+'@'+ OAS_listpos+'!'+pos+OAS_query+'" target="_top">');
  document.write('<img src="'+OAS_url+'adstream_nx.ads/'+OAS_sitepage+'/1'+OAS_rns+'@'+ OAS_listpos+'!'+pos+OAS_query+'" border="0" alt="Werbung" /></a>');
}

function OAS_AD(pos) {
  if (OAS_version >= 11 && typeof(OAS_RICH!='undefined')) {
    OAS_RICH(pos);
  } else {
    OAS_NORMAL(pos);
  }
}

function bannerTopPositioning (w) {
  rp = document.getElementById("banner_top_content");
  rp.style.position = "relativ";
  ml = (770 - w)/2;
  rp.style.left = ml + "px";
}

function rPU() {
  var win = window.open('http://community.sport1.at/cgi-bin/sport1/wwb/wwb.cgi?_CID=reg/index','','scrollbars=yes,resizable,width=645,height=500');
  return false;
}

function openProfil() {
  var win = window.open('http://community.sport1.at/cgi-bin/sport1/wwb/wwb.cgi?_CID=id/index','','scrollbars=yes,resizable,width=640,height=460');
  return false;
}

function openEHProfil(id) {
	var f = window.open("http://www.eishockey.at/spieler/profil.php?id="+id,"p","width=495,height=420,status=no,toolbar=no,menubar=no,resizeable=no,scrollbars=yes");
}


function trendResult(zs, trendid, width, height, typ) {
  var url;
  var found = 0;
  
  if(typ == 1) {
    if(voted[trendid] == 1) {
      countivw();
      alert('Du hast bereits abgestimmt!');
      return false;
    } else {
      for (i=0; i < document.forms['trend'+trendid].aid.length; i++) {
        if (document.forms['trend'+trendid].aid[i].checked) { url = document.forms['trend'+trendid].aid[i].value; found = 1; }
      }

      if(found == 1) { voted[trendid] = 1; } else { alert('Bitte wÃ¤hle zuerst eine Antwort!'); return false; }
    }
  } else { url = zs; }  
  window.open('/'+url,'trend','width='+width+',height='+height+',status=no,toolbar=no,menubar=no,resizeable=no,scrollbars=no');
}

function openPortrait(profil) {
    var win = window.open('http://webat1.laola1.at/sportDB/Fussball/portraits/portrait_'+profil+'.html','spieler','width=495,height=490,toolbar=no,menubar=no,resizable=no,scrollbars=yes');
    return false;
}

function checkSearch() {
  var tmp = document.getElementById("tx_indexedsearch[sword]").value;
  if(tmp != '' && tmp.length > 3) {
    return true;
  } else {
    alert('Bitte gib einen Suchbegriff ein der lÃ¤nger als drei Zeichen ist!');
    countivw();
    return false;
  }
}


function sitestat(ns_l) {
var ns_type='' // leave empty for normal/ppc measurement, fill in for clickin, clickout or pdf
var r='' // yes=only parse url when there is a real document.referrer,
// no=only parse url when there is no real document.referrer, empty=always parse url
var t='?' // tag in url where parameters follow; default '?' could be replaced by "#"
var p=new Array();var w='';var l='';var d=document;var n=navigator;var ns_0=''
;if(top!=self){if('\u0041'=='A'){var u=n.userAgent;if(u.indexOf('Safari')==-1)
{var b=u.indexOf('Opera');if(b==-1||(u.charAt(b+6)+0)>5){b=u.indexOf('Mozilla'
);var xb=b!=-1?u.charAt(b+8)>4:1;if(u.indexOf('compatible')!=-1||xb){var c=
'try{ns_0=top.document.referrer}catch(e){}';eval(c);c=
'try{l=top.document.location.href}catch(e){}';eval(c);}}}}}else{ns_0=
d.referrer;l=d.location.href;}if(ns_0.lastIndexOf('/')==ns_0.length-1){ns_0=
ns_0.substring(ns_0.lastIndexOf('/'),0);}var f=ns_l.indexOf('?');if(f!=-1){
var q=ns_l.substring(f+1);ns_l=ns_l.substring(0,f);if(q){var m=q.indexOf('&');
w=q.substring(0,m==-1?q.length:m);if(w.indexOf('=')!=-1){w='';}if(w){q=
q.substring(m==-1?q.length:m+1);q+=(q?'&':'')+'ns_name='+w;}if(ns_0.length>0){
q+=(q?'&':'')+'ns_referrer='+escape(ns_0);}var s=0;var e=0;while(q.length){e=
q.indexOf('&');if(e==-1){e=q.length;}var o=q.substring(s,e);if(o.substring(0,4
)=='amp;'){o=o.substring(4);}if(o)p[p.length]=o;q=q.substring(e+1);}}}var a=
l.indexOf(t);a=a==-1?0:l.substring(a+1);var j;if(r=='yes')j=ns_0.length;else
if(r=='no')j=!ns_0.length;else if(r=='')j=1;if(a&&j){while(a.length){var e=
a.indexOf('&');if(e==-1){e=a.length;}var k=a.substring(0,a.substring(0,e)
.indexOf('='));var v=a.substring(a.substring(0,e).indexOf('=')+1,e);if(
k.substring(0,4)=='amp;'){k=k.substring(4);}while(v.substring(0,1)=='='){v=
v.substring(1);}if(k=='ns_name'){w=v;}else if(k=='ns_or'){var g='ns_referrer='
;for(var z=0;z<p.length;z++){if(p[z].substring(0,g.length)==g){p[z]=
'ns_referrer='+v;}}}else{if(k.substring(0,3)=='ns_'&&v&&k){var h=0;for(var x=0
;x<p.length;x++){if(p[x].substring(0,p[x].indexOf('='))==k){p[x]=k+"="+v;h=1}}
if(!h){p[p.length]=k+"="+v;}}}a=a.substring(e+1);}}if(!w){return;}var s='';
var y='';for(var i=0;i<p.length;i++)if(p[i].substring(0,8)!='ns_name='){if(p[i
].substring(0,12)!='ns_referrer='){s+='&'+p[i];}else{y='&'+p[i];}}s+=ns_type?
'&ns_type='+ns_type+'&ns_action=view':'';ns_pixelUrl=ns_l+'?'+w+s+"&ns__t="+(
new Date()).getTime();ns_l=ns_pixelUrl+y;window.sp1SitestatSrc = ns_l;if(d.images){ns_1=new Image();
ns_1.src=ns_l;}else{d.write('<img src='+ns_l+' width="1" height="1" name="ns_1">');}}

