

$(document).ready(function() {

 // HACK PRE IE7 - FIXING IE7 Z-INDEX ISSUES WITH JQUERY
var zIndexNumber = 1000;
	$('#header div').each(function() {
		$(this).css('zIndex', zIndexNumber);
		zIndexNumber -= 10;
	});
	


 // Option set as a global variable 3500
		$.fn.loopedSlider.defaults.addPagination = true;
		$('#loopedSlider').loopedSlider({

   autoStart: 6000,
			addPagination: false,
			containerClick: false
		});
			

$(".signin").click(function(e) {
				e.preventDefault();
                $("fieldset#signin_menu").toggle();
				$(".signin").toggleClass("menu-open");
            });

			$("fieldset#signin_menu").mouseup(function() {
				return false
			});
			$(document).mouseup(function(e) {
				if($(e.target).parent("a.signin").length==0) {
					$(".signin").removeClass("menu-open");
					$("fieldset#signin_menu").hide();
				}
			});

 $('#forgot_username_link, .registracia').tipsy({gravity: 'w'});



	$('div.info').css('opacity', 0.0).show();

	$("div.view").hover(function(){
		var id = $(this).attr('id');
		$("div.info[id='i"+id+"']").stop();
		$("div.info[id='i"+id+"']").animate({
			 opacity: 1.0
		}, 500);
	},
	function(){
		var id = $(this).attr('id');
		$("div.info[id='i"+id+"']").stop();
		$("div.info[id='i"+id+"']").animate({
			 opacity: 0.0
		}, 500);
	});


  // OPEN EXTERNAL LINK
  $(".external, .http, a[href*=.pdf]").filter(function() {
    return this.hostname && this.hostname !== location.hostname;
  })
  .click(function() {
    window.open(this.href);
    return false;
  });

// Opens all PDFs in a new window automatically
$("a[href*=.pdf]").click(function(){
	window.open(this.href);
	return false;
});

$('.table').tableHover();




});

    
