neugenug=(document.getElementById)?true:false;
ie55=(window.createPopup)?true:false;
var pics=3;
var waittime=10000;
var first=new Image();
first.src="/images/1.jpg"
var pic = new Array(100);
pic[1] = new Image(); pic[1].src=first.src;
var pre1=new Image();pre1.src='/images/nav_ov.gif';
var pre2=new Image();pre1.src='/images/lang_ov.gif';

function show(nr)
{
if (pic[nr].complete == false){nr=1}
document.images["bild"].src=pic[nr].src;
if (nr<pics){
pic[nr+1]=new Image();
pic[nr+1].src="/images/"+(nr+1)+".jpg"
stimer=setTimeout("snow("+(nr+1)+")",waittime)}
else{
stimer=setTimeout("snow(1)",waittime)}
}

function snow(nr)
{
if (pic[nr].complete == false)
{stimer=setTimeout("snow("+nr+")",500)}
else
{
if (ie55) document.images.bild.filters[0].apply()
document.images["bild"].src=pic[nr].src;
if (ie55) document.images.bild.filters[0].play()
stimer=setTimeout("show("+nr+")",40+pixeldelay)
}
}
function ov(el){
if (!neugenug)return false;
var td=el.parentNode.previousSibling;
while(td.nodeName!='TD')td=td.previousSibling;
if (td.nodeName=='TD'){
	var img=td.firstChild;
	while(img.nodeName!='IMG')td=td.nextSibling;
	if	(img.nodeName=='IMG'&&img.src.substr(img.src.length-5,5)=='p.gif'){
		img.src='/images/nav_ov.gif';
	}
}
}
function ou(el){
if (!neugenug)return false;
var td=el.parentNode.previousSibling;
while(td.nodeName!='TD')td=td.previousSibling;
if (td.nodeName=='TD'){
	var img=td.firstChild;
	while(img.nodeName!='IMG')td=td.nextSibling;
	if	(img.nodeName=='IMG'&&img.src.substr(img.src.length-10,10)=='nav_ov.gif'){
		img.src='/images/p.gif';
	}
}
}
function cl(el){
if (el.blur)el.blur();
return true;
}
function ov2(el,nr){
if (!neugenug)return false;
var img=document.getElementById('lang'+nr);
if	(img.nodeName=='IMG'&&img.src.substr(img.src.length-5,5)=='p.gif'){
		img.src='/images/lang_ov.gif';
}
}
function ou2(el,nr){
if (!neugenug)return false;
var img=document.getElementById('lang'+nr);
if	(img.nodeName=='IMG'&&img.src.substr(img.src.length-11,11)=='lang_ov.gif'){
		img.src='/images/p.gif';
}
}

function ovLi1(el){
if (!neugenug)return false;
el.style.backgroundColor='#E9EDE5';
el.nextSibling.style.backgroundColor='#E9EDE5';
}
function ouLi1(el){
if (!neugenug)return false;
el.style.backgroundColor='#D5DBCC';
el.nextSibling.style.backgroundColor='#D5DBCC';
}

function ovLi2(el){
if (!neugenug)return false;
el.style.backgroundColor='#E9EDE5';
el.previousSibling.style.backgroundColor='#E9EDE5';
}
function ouLi2(el){
if (!neugenug)return false;
el.style.backgroundColor='#D5DBCC';
el.previousSibling.style.backgroundColor='#D5DBCC';
}

function clLi(el,ziel){
if (el.blur)el.blur();
location.href=ziel;
return false;
}

function showBild(ziel,nr){
if (neugenug){
	if (document.getElementById('media')){
		for(var i=1;i<=3;i++){
			if(document.getElementById('bildwahl'+i)){
				if (i==nr)document.getElementById('bildwahl'+i).className='bildwahlsel';else document.getElementById('bildwahl'+i).className='bildwahl';
			}
		}
		for(var i=1;i<=3;i++){
			if(document.getElementById('videowahl'+i)){
				document.getElementById('videowahl'+i).className='bildwahl';
			}
		}
		document.getElementById('media').innerHTML='<img class=pferdebild name=pferdebild src="../../images/hannoveraner/' + ziel + '">';
	}
}
return false;
}

function showVideo(ziel,nr){
if (neugenug){
	if (document.getElementById('media')){
		for(var i=1;i<=3;i++){
			if(document.getElementById('videowahl'+i)){
				if (i==nr)document.getElementById('videowahl'+i).className='bildwahlsel';else document.getElementById('videowahl'+i).className='bildwahl';
			}
		}
		for(var i=1;i<=3;i++){
			if(document.getElementById('bildwahl'+i)){
				document.getElementById('bildwahl'+i).className='bildwahl';
			}
		}
		document.getElementById('media').innerHTML='<object width="425" height="350"><param name="movie" value="http://www.youtube.com/v/' + ziel + '&rel=0"></param><embed src="http://www.youtube.com/v/' + ziel + '&rel=0" type="application/x-shockwave-flash" width="425" height="350"></embed></object>';
	}
}
return false;
}

function start(){
pixeldelay=(ie55)? document.images.bild.filters[0].duration*1000 : 0;
stimer=setTimeout("snow(1)",300);
if (typeof(preload)=='function')preload();
}