//////////////////////////////////////////////////////////////////////////////////////////////////////
// Foncion changerImage(créé par B Lirette le 9 juin 2005)											//
// Fonction qui modifie une image dont le nom a été reçu en argument et modifie le curseur.			//
// source: http://www.kirupa.com/developer/mx/detection.htm											//
//////////////////////////////////////////////////////////////////////////////////////////////////////
function detecterPlugInFlash()
	{
	var intVersionMinimumRequise = 6;
	var plugin = (navigator.mimeTypes && navigator.mimeTypes["application/x-shockwave-flash"]) ? navigator.mimeTypes["application/x-shockwave-flash"].enabledPlugin : 0;
	if ( plugin )
		{
		var words = navigator.plugins["Shockwave Flash"].description.split(" ");
		
		for (var i = 0; i < words.length; ++i)
			{
			if (isNaN(parseInt(words[i])))
			continue;
			var intVersionPlugIn = words[i]; 
			}
		
		var blnFlashEnabled = intVersionPlugIn >= intVersionMinimumRequise;
		}
		else if (navigator.userAgent && navigator.userAgent.indexOf("MSIE")>=0 && (navigator.appVersion.indexOf("Win") != -1))
		{
		document.write('<SCR' + 'IPT LANGUAGE=VBScript\> \n'); //FS hide this from IE4.5 Mac by splitting the tag
		document.write('on error resume next \n');
		document.write('blnFlashEnabled = ( IsObject(CreateObject("ShockwaveFlash.ShockwaveFlash." & intVersionMinimumRequise)))\n');
		document.write('</SCR' + 'IPT\> \n');
		};
			
	if(blnFlashEnabled)
		{
		// let the flow go bro
		//window.location.replace("http://www.apple.com");
		}
		else
		{
		window.location.replace("http://www.noflashforyou.com");
		};
	}

//////////////////////////////////////////////////////////////////////////////////////////////////////
// Foncion changerImage(créé par B Lirette le 9 juin 2005)											//
// Fonction qui modifie une image dont le nom a été reçu en argument et modifie le curseur.			//
//////////////////////////////////////////////////////////////////////////////////////////////////////
function changerImage(strCheminURL, strNomImage, strSuffixe, strExtension, strCurseur)
	{
	document.images[strNomImage].src=strCheminURL+strNomImage+strSuffixe+strExtension;
	}

//////////////////////////////////////////////////////////////////////////////////////////////////////
// Foncion MM_openBrWindow(créé par ??? le 18 octobre 2005)											//
// Fonction qui ouvre un lien dans une nouvelle fenêtre.											//
//////////////////////////////////////////////////////////////////////////////////////////////////////
function MM_openBrWindow(theURL,winName,features)
	{
	window.open(theURL,winName,features);
	}

function openpopup(urlnouv,intWidth,intHeight)
	{
	winpops = window.open(urlnouv,"","width="+intWidth+",height="+intHeight+",");
	}

/*////////////////////////////////////////////////////////////
/	function afficherEtats() (adapté par B. Lirette, 2007-11-07)
/	Fonction qui affiche les images de survol
/	strNomImage		=	nom de l'image à modifier					ie. btn_image_
/	strChemin		=	chemin vers l'image à afficher				ie. medias/images/
/	strEtat			=	nom de l'état à afficher					ie. rl, up
/	strFormat		=	nom de l'extension du fichier à afficher	ie. jpg, gif
////////////////////////////////////////////////////////////*/
function afficherEtats(strNomImage, strChemin, strEtat, strFormat)
	{
	// permet de gérer les mêmes occurrences se répétant dans la page
	strNomFichier = strNomImage.substring(0, strNomImage.length -1);

	// changement d'image
	document.images[strNomImage].src=strChemin+strNomFichier+strEtat+"."+strFormat;
	}