$(function() {
	/**
	 * IE 6 check
	 */
	if ($.browser.msie)
	{
		$('html').addClass('ie');
	
		if($.browser.version.substr(0,1)<7) {
	        $("div#top").before('<div id="IE6check"><span class="close"><img src="public/templates/frontend/images/icons/cross-ie6.gif" width="16" height="16" alt="Sluiten" /></span>U gebruikt momenteel Internet Explorer 6. Wij raden u aan zo spoedig mogelijk de broser te upgraden naar een moderne browser omdat wij de functionaliteit in uw verouderde browser niet kunnen garanderen. Download <a href="http://www.getfirefox" target="_blank">Firefox &raquo;</a> of de laatste versie van <a href="http://www.microsoft.com/windows/internet-explorer/default.aspx" target="_blank">Internet Explorer &raquo;</a>.</div>');
	        $("div#IE6check").click(function () { 
	            $(this).slideUp('slow'); 
	        });
		}
	}
	
	/**
	 * ANTI-SPAM
	 */
	$('#emailcomsi2011')
		.html('info@comsi.nl')
		.bind( 'click', function(){
			window.location.href = "mailto:info@comsi.nl";
		});
	$('.wiw')//wie is wie
		.find('.maskEmail')
		.css('cursor', 'pointer')
		.bind( 'click', function(){
			window.location.href = "mailto:"+$(this).attr('rel')+"@comsi.nl";
		});
	$('.cta')//call to action
		.find('.maskEmail')
		.html( $(this).find('.maskEmail').attr('rel') + '@comsi.nl')
		.css('cursor', 'pointer')
		.bind( 'click', function(){
			window.location.href = "mailto:"+$(this).attr('rel')+"@comsi.nl";
		});
	
	/**
	 * Messages weergeven
	 *   trekt aandacht door animatie
	 */
	$('.msg').slideDown();
	
	
	/**
	 *	FancyBox voor afbeeldingen
	 **/
	if ( typeof($.fn.fancybox) != 'undefined' )
		$('div.content a.fancybox:has(> img)').fancybox( { overlayColor: '#333' } );

});
