function Permut (flag,img) {
	if (document.images) {
		if (document.images[img].permloaded) {
			if (flag==1)
				document.images[img].src = document.images[img].perm.src;
			else
				document.images[img].src = document.images[img].perm.oldsrc;
		}
	}
}
			
function preloadPermut (img,adresse) {
	if (document.images) {
		img.onload = null;
		img.perm = new Image ();
		img.perm.oldsrc = img.src;
		img.perm.src = adresse;
		img.permloaded = true;
	}
}

function lexique(id){
	var largpopup=400;
	var tempx=screen.width-largpopup-5;
	window.open('index.php?cat=lexi&pop=oui&id='+id, "", "scrollbars=yes,menubar=no,toolbar=no,resizable=yes,status=yes,width="+largpopup+",height=400,left="+tempx+",top=0"); 
}

function popup(url){
	var largpopup=400;
	var tempx=screen.width-largpopup-5;
	window.open(url+"&pop=oui", "", "scrollbars=yes,menubar=no,toolbar=no,resizable=yes,status=yes,width="+largpopup+",height=400,left="+tempx+",top=0"); 
}

function resizeOuterTo(w,h) {
	window.resizeTo(w,h);
}

function pop(obj){
	var largpopup=400;
	var tempx=screen.width-largpopup-5;
	window.open(obj.href+"&pop=oui", "", "scrollbars=yes,menubar=no,toolbar=no,resizable=yes,status=yes,width="+largpopup+",height=400,left="+tempx+",top=0"); 
}