function saveFile (fname)
{
	document.execCommand('SaveAs',null,fname)
}


function shiftPic(Mit, MennyivelH)
        {
            if (document.getElementById) // Netscape 6 and IE 5+
            {
                var targetElement = document.getElementById(Mit);
                targetElement.style.backgroundPosition = MennyivelH; 
            }
        }


function cpic(picSrc,picUrlSrc) {
	document.images["preMedPic"].src = picSrc;
	document.all["preMedUrl"].href = picUrlSrc;
}

function showLayer(layerName)
        {
            if (document.getElementById) // Netscape 6 and IE 5+
            {
                var targetElement = document.getElementById(layerName);
                targetElement.style.visibility = 'visible';
            }
        }

function hideLayer(layerName)
        {
            if (document.getElementById) 
            {
                var targetElement = document.getElementById(layerName);
                targetElement.style.visibility = 'hidden';
            }
        }

function toggleLayer(showMe, hideMe) {
	document.all[showMe].style.visibility = 'visible';
	document.all[hideMe].style.visibility = 'hidden';
}


function switchLayer(Mit, Mire) {
	hideLayer(Mit);
	showLayer(Mire);
}

function switch3Layers(Mit, Mit2, Mire) {
	hideLayer(Mit);
	hideLayer(Mit2);
	showLayer(Mire);
}

function switchBioLayer(Mit1,Mit1R,Mit1L, Mit2,Mit2R,Mit2L, Mit3,Mit3R,Mit3L, Mit4,Mit4R,Mit4L, Mit5,Mit5R,Mit5L, Mire,MireR,MireL) {
	hideLayer(Mit1);
	hideLayer(Mit1R);
	hideLayer(Mit1L);
	hideLayer(Mit2);	
	hideLayer(Mit2R);	
	hideLayer(Mit2L);
	hideLayer(Mit3);
	hideLayer(Mit3R);
	hideLayer(Mit3L);
	hideLayer(Mit4);	
	hideLayer(Mit4R);	
	hideLayer(Mit4L);
	hideLayer(Mit5);
	hideLayer(Mit5R);
	hideLayer(Mit5L);
	showLayer(Mire);
	showLayer(MireR);
	showLayer(MireL);
}

function switchTitlesLayer(Mit1,Mit1s, Mit2,Mit2s, Mit3,Mit3s, Mit4,Mit4s, Mit5,Mit5s, Mire,Mires) {
	hideLayer(Mit1);
	hideLayer(Mit1s);
	hideLayer(Mit2);	
	hideLayer(Mit2s);
	hideLayer(Mit3);
	hideLayer(Mit3s);
	hideLayer(Mit4);	
	hideLayer(Mit4s);
	hideLayer(Mit5);
	hideLayer(Mit5s);
	showLayer(Mire);
	showLayer(Mires);
}

function switch3TitlesLayer(Mit1,Mit1s, Mit2,Mit2s, Mire,Mires) {
	hideLayer(Mit1);
	hideLayer(Mit1s);
	hideLayer(Mit2);	
	hideLayer(Mit2s);
	showLayer(Mire);
	showLayer(Mires);
}


function changeId(Mit, Mire) {

	identity=document.getElementById(Mit);
        identity.className=Mire;

}