function clearInputField(field,defaultValue){
	if(field && field.type=="text"){
		if(field.value==defaultValue) field.value="";
		if(!field.onblur){
			field.onblur=function(){
				if(this.value=="") this.value=defaultValue;
			}
		}
	}
}
function ci(f) {
	if (f.name.value == "Name, Firma, Branchen, Produkte, Telefonnummer") f.name.value= "";
	if (f.location.value == "PLZ, Ort") f.location.value= "";
	return true;
}
function PanoKlein(Adresse) {
	var w= 800;
	var h= 600;
	WPanoKlein= window.open("http://www.telaustria.at/" + Adresse, "PanoKlein", "width=" + w + ",height=" + h + ",fullscreen=no, resizable=no, scrollbars=auto,toolbar=no,status=no");
	WPanoKlein.moveTo((screen.width-w)/2, (screen.height-h)/2);
	WPanoKlein.focus();
}
function showAudio(urlAudio) {
	var w= 550;
	var h= 295;
	var adr= "http://media.telaustria.at/audio/" + urlAudio + "/flash.html";
	WAudio= window.open(adr, "AudioScore", "width=" + w + ",height=" + h + ",fullscreen=no, resizable=no, scrollbars=no,toolbar=no,status=no");
	WAudio.moveTo((screen.width-w)/2, (screen.height-h)/2);
	WAudio.focus();
}
function showVideo(urlVideo) {
	var w= 530;
	var h= 318;
	WVideo= window.open("http://www.telaustria.at/video.do?video="+urlVideo, "Video", "width=" + w + ",height=" + h + ",fullscreen=no, resizable=no, location=no, scrollbars=no,toolbar=no,status=no");
	WVideo.moveTo((screen.width-w)/2, (screen.height-h)/2);
	WVideo.focus();
}
function byId(e) {
	return document.getElementById(e);
}
var slidepos= 0;
var slidedelta= 175;
function slide(pos) {
	byId("mediaListe").style.marginLeft= pos + "px";
}
function sliderLinks() {
	if (slidepos + slidedelta <= 0)
		slidepos+= slidedelta;
	else
		slidepos= 0;
	slide(slidepos);
}
function sliderRechts() {
	if ((-1) * (anzmedia-2) * slidedelta < slidepos - slidedelta) {
		slidepos-= slidedelta;
		slide(slidepos);
	}
}
var ua = navigator.userAgent.toLowerCase();
var NS4 = (document.layers) ? true : false;
var DOM = (document.getElementById) ? true : false;
var IE4 = (document.all) ? true : false;
var isOpera = (ua.indexOf("opera") != -1) ? true : false;
//offset = 270;
var offset;
if (offset == undefined) {
	offset = 270;
}
function fix() { 

	if(document.body.scrollHeight < document.documentElement.clientHeight) {
			document.getElementById("container").style.height=document.documentElement.clientHeight-offset+"px";
	}
}
if (NS4) {window.captureEvents(Event.RESIZE)}
window.onresize=fix;
