﻿/*.....funktion für Suckerfish-menu.........*/
			function sfHover() {
					$("#mainnavi li").hover(
					function(){
						$(this).addClass('sfhover');
						$(this).find('a:first').addClass('sfhovera');
					},
					function(){
						$(this).removeClass('sfhover');
						$(this).find('a:first').removeClass('sfhovera');
					})
				
			}
						/*sfHover = function() {
				var sfEls = document.getElementById("mainnavi").getElementsByTagName("LI");
				for (var i=0; i<sfEls.length; i++) {
					sfEls[i].onmouseover=function() {
						this.className+=" sfhover";
					}
					sfEls[i].onmouseout=function() {
						this.className=this.className.replace(new RegExp(" sfhover\\b"), "");
					}
				}
			}*/

function onBefore() { 
    $('#slidetitle').fadeOut(500).html(); 
} 
function onAfter() { 
$('#slidetitle').html(this.title).fadeIn(500); 
}

$(document).ready(function(){
var so = new SWFObject("files/flash/header1.swf", "ad63", "300", "75", "8", "#333333", true);
  				 so.addParam("quality", "high");
				 so.addParam("align", "middle");
				 so.addParam("play", "true");
				 so.addParam("loop", "true");
				 so.addParam("scale", "showall");
                // so.addParam("wmode", "opaque");
				 so.addParam("devicefonts", "false");
				 so.addParam("menu", "true");
				 so.addParam("name", "bnr63");
				 so.addParam("allowFulSreen", "false");
				 so.addParam("allowScriptAccess","sameDomain");
                so.write("h1");
var so2 = new SWFObject("files/flash/header2.swf", "ad63", "300", "75", "8", "#333333", true);
  				 so2.addParam("quality", "high");
				 so2.addParam("align", "middle");
				 so2.addParam("play", "true");
				 so2.addParam("loop", "true");
				 so2.addParam("scale", "showall");
                 //so2.addParam("wmode", "opaque");
				 so2.addParam("devicefonts", "false");
				 so2.addParam("menu", "true");
				 so2.addParam("name", "bnr63");
				 so2.addParam("allowFulSreen", "false");
				 so2.addParam("allowScriptAccess","sameDomain");
                so2.write("h2");				
sfHover();
$('#slideshow').cycle({ 
    fx:     'fade', 
    timeout: 8000, 
	delay:  -2000,
	speed: 1500,
	next:   '#next',
	prev: '#prev',
    pause:   1 
 });
$('#next,#prev').hover(
function(){
	img=$('img',this).attr('src');
	img=img.replace('.png','_hover.png');
	$('img',this).attr('src',img);
},
function(){
		img=$('img',this).attr('src');
	img=img.replace('_hover.png','.png');
	$('img',this).attr('src',img);
})
$("a.lightbox").colorbox({transition:"fade",current:'',previous:'zurück',next:'vor',close:'schließen',maxHeight:'600px'});
$("a.iframe").colorbox({transition:"fade",'iframe':true,width:"80%", height:"80%",close:'schließen'});
/* input animation */
$('input:not(input[type=submit])').focus(function(){
$(this).css('background-color','#fff');
$(this).css('border-color','#333');
}).blur(function(){
$(this).css('background-color','#e3e4e4');
$(this).css('border-color','#333');

})
$('textarea').focus(function(){
$(this).css('background-color','#fff');
$(this).css('border-color','#333');
}).blur(function(){
$(this).css('background-color','#e3e4e4');
$(this).css('border-color','#333');

})
$('input[type=reset],input[type=submit]').hover(function(){
	$(this).css({'text-decoration':'none','color':'#333','background':'url(files/images/link_gruen_weiss_hover.gif) no-repeat right'});
},function(){
	$(this).css({'text-decoration':'underline','color':'#009036','background':'url(files/images/link_gruen_weiss.gif) no-repeat right'});
}).css({'text-decoration':'underline','color':'#009036','background':'url(files/images/link_gruen_weiss.gif) no-repeat right'});

})
