/* --------------------------------------------*/
/* ---------------BROWSER-CHECK----------------*/
/* --------------------------------------------*/

/* Browser Check Anfang */
var b
//alert(navigator.appName + " " + navigator.appVersion)

if (navigator.appName=="Microsoft Internet Explorer") b=0
if (navigator.appName=="Netscape" && navigator.appVersion < "5") b=14
if (navigator.appName=="Netscape" && navigator.appVersion > "5") b=16
if (navigator.appName=="Opera" && navigator.appVersion < "6.99") b=26
if (navigator.appName=="Opera" && navigator.appVersion > "6.99" && navigator.appVersion < "8.99") b=27
if (navigator.appName=="Opera" && navigator.appVersion > "8.99") b=29

//alert(b)

/* Ueberpruefung des 'MSIE'-Strings des Internet Explorers Anfang*/
if (b==0 || b==2)
{
	var na=navigator.appVersion
	var mstring = na.indexOf("MSIE")
	var pos = na.substring(mstring+5, mstring+6)
}
/* Ueberpruefung des 'MSIE'-Strings des Internet Explorers Ende*/

/* Browser Check Ende */

/* Auswahl der an Browser angepassten Style-Sheets Anfang */
if (b==16 || b==29) document.write("<LINK REL='stylesheet' HREF='http://www.kleinezeitung.at/portal/css/styles_ns7.css'>")
if (b==27) document.write("<LINK REL='stylesheet' HREF='http://www.kleinezeitung.at/portal/css/styles_opera.css'>")
/* Auswahl der an Browser angepassten Style-Sheets Ende */

/* --------------------------------------------*/
/* -----------------FUNKTIONEN-----------------*/
/* --------------------------------------------*/

function popup(url, breite, hoehe, scroll)
{
	zufall = Math.random()
	var jetzt = new Date();
	var seks = jetzt.getSeconds()
	var zufallszahl = Math.floor(zufall * seks)
	var picWindow = "picWindow" + zufallszahl
	
	var derScroll = scroll
	if (derScroll == "1") scrolling = "yes"
	if (derScroll == undefined || derScroll > "1") scrolling = "no"
	
	window.open(url, picWindow, "menubar=no,location=no,resizable=no,status=no,toolbar=no,scrollbars=" + scrolling + ",width=" + breite + ",height=" + hoehe + ",screenX=20,screenY=20")
}

function popupret(url, breite, hoehe, scroll)
{
	zufall = Math.random()
	var jetzt = new Date();
	var seks = jetzt.getSeconds()
	var zufallszahl = Math.floor(zufall * seks)
	var picWindow = "picWindow" + zufallszahl
	
	var derScroll = scroll
	if (derScroll == "1") scrolling = "yes"
	if (derScroll == undefined || derScroll > "1") scrolling = "no"
	
	wname=window.open(url, picWindow, "menubar=no,location=no,resizable=no,status=no,toolbar=no,scrollbars=" + scrolling + ",width=" + breite + ",height=" + hoehe + ",screenX=20,screenY=20")
	return wname;
}

function chgSel()
{
	document.location.href = document.getElementById('auswahl').value

}

function zaehleAlsStartseiteViaNedstat(){
	var http = false;
	if(navigator.appName == "Microsoft Internet Explorer"){
		http = new ActiveXObject("Microsoft.XMLHTTP");
	} else {
		http = new XMLHttpRequest();
	}
	http.open('GET','/portal/services/integration/alsstartseite_nedstat_proxy.jsp',true);
	http.send(null);
}
function zaehleFotoclickNoAd(page) { //kein Werbungreload
var element=document.getElementById("fuss2");
// Nedstat
	if ((typeof(nedstatpathnopageandcategory)!="undefined")&&(typeof(nedstatcategory)!="undefined")){
		var NewPixNedstat = document.createElement("img");
  		NewPixNedstat.setAttribute("SRC", nedstatpathnopageandcategory + page + nedstatcategory +"&d="+(new Date()).getTime()+"", "false");
  		NewPixNedstat.setAttribute("width","1", "false");
  		NewPixNedstat.setAttribute("height","1", "false");
  		element.appendChild(NewPixNedstat);
	}
// OEWA 
	if (typeof(OEWA)!="undefined"){
		var NewPixOewa = document.createElement("img");
  		NewPixOewa.setAttribute("SRC", OEWA + "?d="+(new Date()).getTime()+"", "false");
  		NewPixOewa.setAttribute("width","1", "false");
  		NewPixOewa.setAttribute("height","1", "false");
  		element.appendChild(NewPixOewa);
	}
//XITI
   if ((typeof (xiti_base)!="undefined")&&(typeof (xiti_lastparams)!="undefined")){
  	    var xiti_page=page;
   	    if ((typeof (page)!="undefined")&&(typeof (page)=="string")){   	     
   	      xiti_page=page.replace(".","::");
   	    }
   		var NewPixXiti = document.createElement("img");	
   		NewPixXiti.setAttribute("SRC", xiti_base +xiti_page+xiti_lastparams+ "dx="+(new Date()).getTime()+"", "false");
   		NewPixXiti.setAttribute("width","1", "false");
   		NewPixXiti.setAttribute("width","1", "false");   	  
   }		
// Google Analytics
	_uacct = "UA-3159206-1";
	urchinTracker();
}

function zaehleFotoclick(page) {
var element=document.getElementById("fuss2");
// Nedstat
	if ((typeof(nedstatpathnopageandcategory)!="undefined")&&(typeof(nedstatcategory)!="undefined")){
		var NewPixNedstat = document.createElement("img");
  		NewPixNedstat.setAttribute("SRC", nedstatpathnopageandcategory + page + nedstatcategory +"&d="+(new Date()).getTime()+"", "false");
  		NewPixNedstat.setAttribute("width","1", "false");
  		NewPixNedstat.setAttribute("height","1", "false");
  		element.appendChild(NewPixNedstat);
	}
// OEWA 
	if (typeof(OEWA)!="undefined"){
		var NewPixOewa = document.createElement("img");
  		NewPixOewa.setAttribute("SRC", OEWA + "?d="+(new Date()).getTime()+"", "false");
  		NewPixOewa.setAttribute("width","1", "false");
  		NewPixOewa.setAttribute("height","1", "false");
  		element.appendChild(NewPixOewa);
	}
//XITI
   if ((typeof (xiti_base)!="undefined")&&(typeof (xiti_lastparams)!="undefined")){
   	    var xiti_page=page;
   	    if ((typeof (page)!="undefined")&&(typeof (page)=="string")){   	     
   	      xiti_page=page.replace(".","::");
   	    }
   		var NewPixXiti = document.createElement("img");	
   		NewPixXiti.setAttribute("SRC", xiti_base +xiti_page+xiti_lastparams+ "dx="+(new Date()).getTime()+"", "false");
   		NewPixXiti.setAttribute("width","1", "false");
   		NewPixXiti.setAttribute("width","1", "false");   	  
   }	
// Google Analytics
	_uacct = "UA-3159206-1";
	urchinTracker();
	//reloadWerbung
	if (typeof (writeAdsFrame)== "function"){
		writeAdsFrame();
	}	
}
function zaehleClickFuerStatisikNoAd(nedstat, oewa) { //kein Werbungreload
var element=document.getElementById("fuss2");
// Nedstat
	var NewPixNedstat = document.createElement("img");
  	NewPixNedstat.setAttribute("SRC", nedstat + "&d="+(new Date()).getTime()+"", "false");
  	NewPixNedstat.setAttribute("width","1", "false");
  	NewPixNedstat.setAttribute("height","1", "false");
  	element.appendChild(NewPixNedstat);
// OEWA 
	var NewPixOewa = document.createElement("img");
  	NewPixOewa.setAttribute("SRC", oewa + "?d="+(new Date()).getTime()+"", "false");
  	NewPixOewa.setAttribute("width","1", "false");
  	NewPixOewa.setAttribute("height","1", "false");
  	element.appendChild(NewPixOewa);
//XITI
   if (typeof (xiti_path)!="undefined"){
   		var NewPixXiti = document.createElement("img");	
   		NewPixXiti.setAttribute("SRC", xiti_path + "dx="+(new Date()).getTime()+"", "false");
   		NewPixXiti.setAttribute("width","1", "false");
   		NewPixXiti.setAttribute("width","1", "false");
   }
// Google Analytics
	_uacct = "UA-3159206-1";
	urchinTracker();
}

function zaehleClickFuerStatisik(nedstat, oewa) {
var element=document.getElementById("fuss2");
// Nedstat
	var NewPixNedstat = document.createElement("img");
  	NewPixNedstat.setAttribute("SRC", nedstat + "&d="+(new Date()).getTime()+"", "false");
  	NewPixNedstat.setAttribute("width","1", "false");
  	NewPixNedstat.setAttribute("height","1", "false");
  	element.appendChild(NewPixNedstat);
// OEWA 
	var NewPixOewa = document.createElement("img");
  	NewPixOewa.setAttribute("SRC", oewa + "?d="+(new Date()).getTime()+"", "false");
  	NewPixOewa.setAttribute("width","1", "false");
  	NewPixOewa.setAttribute("height","1", "false");
  	element.appendChild(NewPixOewa);
//XITI
   if (typeof (xiti_path)!="undefined"){
   		var NewPixXiti = document.createElement("img");	
   		NewPixXiti.setAttribute("SRC", xiti_path + "dx="+(new Date()).getTime()+"", "false");
   		NewPixXiti.setAttribute("width","1", "false");
   		NewPixXiti.setAttribute("width","1", "false");
   }  	
// Google Analytics
	_uacct = "UA-3159206-1";
	urchinTracker();
	//reloadWerbung
	if (typeof (writeAdsFrame)== "function"){
		writeAdsFrame();
	}	
}
