function imgSwap(oImg)
{
   var strOver  = "_on"    // image to be used with mouse over
   var strOff = "_off"     // normal image
   var strImg = oImg.src
   if (strImg.indexOf(strOver) != -1) 
      oImg.src = strImg.replace(strOver,strOff)
   else
      oImg.src = strImg.replace(strOff,strOver)
}

sfHover = function() {
	var sfEls = document.getElementById("sidebar").getElementsByTagName("LI");
	for (var i=0; i<sfEls.length; i++) {
		sfEls[i].onmouseover=function() {
			this.className+=" sfhover";
		}
		sfEls[i].onmouseout=function() {
			this.className=this.className.replace(new RegExp(" sfhover\\b"), "");
		}
	}
}
validateIe = function(){
		if(( /msie/i.test(navigator.userAgent) && !/opera/i.test(navigator.userAgent) )){document.getElementById('makehomepage').style.display='';}
}
if (window.attachEvent) window.attachEvent("onload", sfHover);
if (window.attachEvent) window.attachEvent("onload", validateIe);

function homepage(){
		document.body.style.behavior='url(#default#homepage)';
		document.body.setHomePage('http://www.telvic.com');
}

function updateTotal(){
	b = document.getElementsByTagName('input');
	for(i=0;i<b.length;i++){
		if(b[i].getAttribute('type')=='radio' && b[i].checked != false){val=b[i].value;}
	}
	if(parseInt(val)==1){
		total = 16.63;
		type='prixRes';
	}else{
		total = 37.63;
		type='prixAff';
	}
	a=document.getElementsByTagName('input');
	for(i=0;i<a.length;i++){
		if(a[i].checked==true && a[i].getAttribute("type")=='checkbox'){
			total+=parseInt(a[i].getAttribute(type));
		}
	}
	document.formulaire.total.value=total+'$';
}