//main navigation - jqdock menu - jqdock
jQuery(document).ready(function($){
  // set up the options to be used for jqDock...
  var dockOptions =
    { align: 'bottom' // horizontal menu, with expansion UP from a fixed BOTTOM edge
    //, labels: true  // add labels (defaults to 'tc')
    , size: 62
    , fadeIn: 1250
    };
  // ...and apply...
$('#main-nav').jqDock(dockOptions);
});

//images right mouse click uitschakelen

function disableclick(e) {
if (document.all) {
if (event.button==2||event.button==3) {
if (event.srcElement.tagName=="IMG"){
return false;
}
}
}
else if (document.layers) {
if (e.which == 3) {
return false;
}
}
else if (document.getElementById){
if (e.which==3&&e.target.tagName=="IMG"){
return false
}
}
}

function associateimages(){
for(i=0;i<document.images.length;i++)
document.images[i].onmousedown=disableclick;
}

if (document.all)
document.onmousedown=disableclick
else if (document.getElementById)
document.onmouseup=disableclick
else if (document.layers)
associateimages()

//close and hide - jq ui effect fold
$(function() {
  	$("#close-layer").click(function () {
			$("#close-layer").hide();
			$("#img0").hide();
			$("#close").fadeOut(1300);
     		$("#layout-wrap").hide("fold", {}, 2500);
	});
});



$(document).ready(function() { 

var month = '';
// news maand kopjes
$('.news-header-list-container').find('.month').each(function() {
	if ($(this).html() != month) {
		month = $(this).html()
		$(this).parent().parent().prepend('<div class="month_header">'+month+'</div>');
	}
});


//beursindex
		$('#beursindex').attr('loaded','1'); 
		
		$('#beursindex').load("/index.php?id=570", function() {
				$('#beursindex').css('background-image','none'); 
				$('#beursindex').attr('loaded','1'); 
		}); 
});

//beursindex
$("#beurswrap").hover(function() {
	if ($('#beursindex').attr('loaded') != '1') {
		$('#beursindex').attr('loaded','1');
		
		$('#beursindex').load("/index.php?id=570", function() {
				$('#beursindex').css('background-image','none');
				$('#beursindex').attr('loaded',1);
		});
	}
	
	$("#beursindex").animate({"opacity": "1"}, "slow");
},function() {
	$("#beursindex").animate({"opacity": "0"}, "slow");
});

