﻿function mainmenu(){
$(" #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"});
		});
}
 
$(document).ready(function(){					
	mainmenu();
	
	$('#menu a').mouseover(function () {
		$(this).children().attr('src',$(this).children().attr('src').replace('1','2'));	
    });
	
	$('#menu a').mouseout(function () {
		$(this).children().attr('src',$(this).children().attr('src').replace('2','1'));
    }); 
});

//function pop(name){
//window.open ('actu_pop.php?name=' + name, '_blank', 'toolbar=no, menubar=no, resizable=yes, location=no, status=no');
//}

function pop(img) { 
titre="Agrandissement"; 
w=open("",'image','width=400,height=400,toolbar=no,scrollbars=no,resizable=no'); 
w.document.write("<html><head><title>"+titre+"</title></head>"); 
w.document.write("<script language=javascript>function checksize() { if (document.images[0].complete) { window.resizeTo(document.images[0].width+20,document.images[0].height+90); window.focus();} else { setTimeout('checksize()',250) } }</"+"script>"); 
w.document.write("<body onload='checksize()' onblur='window.close()' onclick='window.close()' leftMargin=0 topMargin=0 marginwidth=0 marginheight=0>");
w.document.write("<table width='100%' border='0' cellspacing='0' cellpadding='0' height='100%'><tr>");
w.document.write("<td valign='middle' align='center'><img src='images/"+img+"' border=0 alt='Mon image'>"); 
w.document.write("</td></tr></table>");
w.document.write("</body></hmtl>"); 
w.document.close(); 
} 




