// JavaScript Document
$(document).ready(function() {
						   
	$('.nieuws .nieuwsItemDescLong').css('display', 'none');
	$('.content .nieuwsItemDescShort').css('display', 'none');
	
	if($(location).attr('hash') == "") {
		$('.content .nieuwsItemDescLong').css('display', 'none');
		$('.content .nieuwsItemDescShort').css('display', '');
		
		$('.content li').click(function() {		 
				$('.content .nieuwsItemDescShort').show();
				$('.content .nieuwsItemDescLong').hide();
				$(this).find('.nieuwsItemDescShort').hide();
				$(this).find('.nieuwsItemDescLong').show();
		});	
	}
	
	$('#password').focus(function() {  $(this).removeClass('password') });
	$('#password').blur(function() { 
		if ($(this).attr("value") == '') {
			$(this).addClass('password')
		}
	});


	$('#user').focus(function() {  $(this).removeClass('user') });
	$('#user').blur(function() { 
		if ($(this).attr("value") == '') {
			$(this).addClass('user')
		}
	});

	$('#admin').focus(function() {  $(this).removeClass('admin') });
	$('#admin').blur(function() { 
		if ($(this).attr("value") == '') {
			$(this).addClass('admin')
		}
	});
})

function openFooter(){
	if(document.getElementById('container_contact').style.display == 'none'){
		$('#container_contact').slideDown("slow")
		mOn(document.getElementById('footerOpenBtn'))
		document.getElementById('container_contact').style.display = 'block'
	}else{
		$('#container_contact').slideUp("slow")
		mOut(document.getElementById('footerOpenBtn'))
		document.getElementById('container_contact').style.display = 'none'
	}
}

function mOn(obj) {
	var ext = obj.src.slice(-3)
	if(obj.src.indexOf('_o.'+ ext)==-1){
		obj.src=obj.src.replace('.'+ ext,'_o.'+ ext)
	}
}
function mOut(obj) {
	var ext = obj.src.slice(-3)
	obj.src=obj.src.replace('_o.'+ext,'.'+ext)
}

