function addEvents(oElem,sEvent,fn){return oElem.addEventListener?oElem.addEventListener(sEvent,fn,false):oElem.attachEvent?oElem.attachEvent('on'+sEvent,fn):oElem['on'+sEvent]=fn;}function windowPrint(oElem,sText,iPos){if(window.print&&document.getElementById(oElem)&&sText!=''){var oEl=document.getElementById(oElem);var oA=document.createElement('a');oA.setAttribute('href','#');oA.appendChild(document.createTextNode(sText));oA.onclick=function(){window.print();return false;};var bInsert=false,cpt=0;i=0;if(oEl.tagName=="UL"||oEl.tagName=="OL"){if(oEl.childNodes||oEl.childNodes.length>0){var oLi=document.createElement('li');oLi.appendChild(oA);while(i<oEl.childNodes.length&&!bInsert){if(oEl.childNodes[i].nodeName=="LI"){if(++cpt==iPos){oEl.insertBefore(oLi,oEl.childNodes[i]);bInsert=true;}}i++;}}if(!bInsert)oEl.appendChild(oLi);}else oEl.appendChild(oA);}};function langue(sMot,aRemplace){if(typeof(langueJS)!="undefined"){var s=langueJS[sMot];if(aRemplace)for(var i=0;i<aRemplace.length;i++)s=s.replace(aRemplace[i][0],aRemplace[i][1]);return s;}else return "Erreur traduction : "+sMot;};document.getElementsByClass=function(nomClass,node,tag){var i,j,classElements=new Array();if(node==null)node=document;if(tag==null)tag='*';var els=node.getElementsByTagName(tag);var elsLen=els.length;var pattern=new RegExp("(^|\\s)"+nomClass+"(\\s|$)");for(i=0,j=0;i<elsLen;i++){if(pattern.test(els[i].className))classElements[j++]=els[i];}return classElements;};