function redimIFrame( obj ) 
{ 
try {
	document.getElementById(obj.id).height=window.frames[obj.name].document.body.scrollHeight;
	}catch(ex){}
window.scrollTo(0,0);
}

function tabbedOver(theTable, selected) {
	theTable.className = 'activeTab';
	theTable.getElementsByTagName('td')[1].className = 'activeMiddle';
	theTable.getElementsByTagName('td')[3].className = 'activeBottomCell';
	theTable.getElementsByTagName('a')[0].className= 'tabLinkActive';
}

function tabbedOut(theTable, active) {
	if(active == 0) // false
	{
		theTable.className = 'inactiveTab';
		theTable.getElementsByTagName('td')[1].className = 'inactiveMiddle';
		theTable.getElementsByTagName('td')[3].className = 'inactiveBottomCell';
		theTable.getElementsByTagName('a')[0].className= 'tabLink';
	} else {
		theTable.className = 'activeTab';
		theTable.getElementsByTagName('td')[1].className = 'activeMiddle';
		theTable.getElementsByTagName('td')[3].className = 'activeBottomCell';
		theTable.getElementsByTagName('a')[0].className= 'tabLinkActive';
	}
}

// Small description window open routine
function descWindow(url){
	var top = (screen.height-550)/2;
	var left = (screen.width-600)/2;
	newWin = window.open(url,"","top="+top+",left="+left+",width=600,height=550,resizable=yes,menubar=no,scrollbars,directories=no,status=no,toolbar=no,location=no");
	newWin.focus();
}

function popup(page,largeur,hauteur,options)
{ 
	var top = (screen.height-hauteur)/2;
	var left = (screen.width-largeur)/2;
	newWin = window.open(page,"","top="+top+",left="+left+",width="+largeur+",height="+hauteur+","+options);
	newWin.focus();
}

function imgSwap(pic1,pic2)
{
	if (document.images)
	{
		document.images[pic1].src = eval(pic2 + ".src");
	}
}

if (document.images)
{
	fermer1 = new Image( );
	fermer1.src = "/jsp/jahia/templates/manpower/manpower_templates/img/manpower_bt_fermer_off.gif";
	fermer2 = new Image( );
	fermer2.src = "/jsp/jahia/templates/manpower/manpower_templates/img/manpower_bt_fermer_on.gif";
}