$(document).ready(function(){

$(" #nav ul ").css({display: "none"}); // Opera Fix
$(" #nav li").hover(function(){
		$(this).find('ul:first').css({visibility: "visible",display: "none"}).show(400);
		},function(){
		$(this).find('ul:first').css({visibility: "hidden"});
		});


    $("#scroll").jCarouselLite({
        btnNext: ".next",
        btnPrev: ".prev",
		vertical: true,
		visible:4,
        speed: 500

    });
$('a.zoom').zoomimage();

$("select#go").change(function() {
	window.location = $(this).val();
	});


$('div.panel').hide();
//setTimeout(function() {	 $('div#panel2').slideDown(1000);} , 1000);

	$("a.btn-slide[id]").click(function(){
	
	
	 var id= $(this).attr('id');
tabs(id);
	 $("div.panel").slideUp(500);
	 $('#panel'+id).animate({opacity: 1.0}, 1400);
	 $("#panel"+id).slideDown(500);
	 
	});
	

function tabs(id)
{
setTimeout(function() {	
var newId=id-1;
$('span').addClass("topper");
//$('p.'+id).removeClass("topper"); 
$("span:eq("+newId+")").removeClass("topper"); 
}, 1000);

}


 $("img[src]").click(function(){ 
$('a.btn-slide img').each(function(){	 this.src = this.src.replace( /\_on.gif$/, '.gif' ); });
 this.src = this.src.replace( /\.gif$/, '_on.gif' );

 });
 


					$('ul#webcam').animatedinnerfade({
						speed: 2000,
						timeout: 15000,
						type: 'sequence',
						containerheight: '400px',
						containerwidth: '525px',
						animationSpeed: 15000,
						animationtype: 'fade',
						bgFrame: 'public/templates/oostenrijk/css/image/frame.gif',
	                                        controlBox: 'show',
						controlBoxClass: 'mycontrolboxclass',
	                                        controlButtonsPath: 'public/templates/oostenrijk/css/image',
                                                displayTitle: 'yes' 
					});
 $('a.zoom').zoomimage();					

 
	 
});