window.onerror=stoperror

function stoperror() {
 return true
}

function VersionNavigateur(Netscape, Explorer) {
  if ((navigator.appVersion.substring(0,3) >= Netscape && navigator.appName == 'Netscape') ||      
      (navigator.appVersion.substring(0,3) >= Explorer && navigator.appName.substring(0,9) == 'Microsoft'))
    return true;
else return false;
}

var isNS=(navigator.appName == "Netscape" && parseInt(navigator.appVersion) >= 4)
var isMAC=(navigator.appVersion.indexOf("Mac")!=-1)
var isIE5=(navigator.appVersion.indexOf("MSIE 5")!=-1)

//setTimeout ("changePage()", 3000)

function changePage() {
 if (self.parent.frames.length != 0) {
  self.parent.location = self.location
 }
}

function inj(c) {
 document.write(c)
}

function initArray() {
 this.length = initArray.arguments.length;
 for (var j = 0; j < this.length; j++) {
  this[j] = initArray.arguments[j];
 }
}

function MakeArray(n) {
 this.length = n
 return this
}

if (VersionNavigateur(4.0,4.0)) {
}
else {
 resultat = confirm('Désolé mais le navigateur que vous utilisez est trop ancien pour vous permettre de visiter notre site. Voulez-vous nous écrire pour en savoir plus ?')
 if(resultat == "1") {
  document.location = "mailto:technique@isdo.net?subject=Problème de navigateur"
 }
}

function montrerObjet(objet) {
 objet.visibility = VISIBLE
}

function cacherObjet(objet) {
 objet.visibility = HIDDEN
}

function infolegales(){
 window.open("infolegales.html","infolegales","width=300,height=250,toolbar=no,resizable=yes,scrollbars=no")
}

function verif() {
 var zone=document.location.toString()
 if (zone.substring(0,7) != "http://") {
  resultat = confirm("Vous ne pouvez vous abonner à la liste de diffusion du groupe I.S.D.O.\nque lorsque vous utilisez la version sur l\'Internet.\n\nVoulez-vous basculer sur la version en ligne du site, www.isdo.net ?")
  if(resultat == "1") {
   document.location = "http://www.isdo.net"
  }
  return false
 }
 else {
  if ((document.liste.Adresse.value == "") || (document.liste.Adresse.value == "nom@monprovider.com")) {
   alert("Vous devez spécifier votre adresse électronique ...")
   document.liste.Adresse.select()
   return false
  }
  if (document.liste.Adresse.value != "") {
   window.document.liste.submit()
   return true
  }
 }
}

function verif2() {
 var zone = document.location.toString()
 if (zone.substring(0,7) != "http://") {
  resultat = confirm("Vous ne pouvez vous abonner à la liste de diffusion du groupe I.S.D.O.\nque lorsque vous utilisez la version sur l\'Internet.\n\nVoulez-vous basculer sur la version en ligne du site, www.isdo.net ?")
  if(resultat == "1") {
   document.location = "http://www.isdo.net"
  }
  return false
 }
 else {
  if ((document.liste2.Adresse.value == "") || (document.liste2.Adresse.value == "nom@monprovider.com")) {
   alert("Vous devez spécifier votre adresse électronique ...")
   document.liste2.Adresse.select()
   return false
  }
  if (document.liste2.Adresse.value != "") {
   window.document.liste2.submit()
   return true
  }
 }
}

function verifIntervention() {
 var zone = document.location.toString()
 if (zone.substring(0,7) != "http://") {
  resultat = confirm("Vous ne pouvez vous laisser un message\nque lorsque vous utilisez la version sur l\'Internet.\n\nVoulez-vous basculer sur la version en ligne du site,\nwww.PassionWebmaster.com ?")
  if(resultat == "1") {
   document.location = "http://www.passionwebmaster.com"
  }
  return false
 }
 else {
  if (document.formulaire.Adresse.value == "" && document.formulaire.Adresse_confidentielle.checked == false) {
   alert("Merci de nous communiquer votre adresse électronique ...")
   document.formulaire.Adresse.select()
   return false
  }
  else {
   window.document.formulaire.submit()
   return true
  }
 }
}

function ouvrirPhoto(url,x,y) {
 if (url != "") {
  x=x+18
  y=y+23
  var MinWin, winOpts="width="+x+",height="+y+",resizable=yes,scrollbars=no,toolbar=no,location=no,directories=no,status=no"
  if (((navigator.appName == "Microsoft Internet Explorer") && (parseInt(navigator.appVersion)>3)) || (navigator.appName == "Netscape")) {
   pere=top
  }
  nouvelle_fenetre=window.open(url,'', winOpts)  
  if (((navigator.appName == "Microsoft Internet Explorer") && (parseInt(navigator.appVersion)>3)) || (navigator.appName == "Netscape")) {
   nouvelle_fenetre.pere=pere
  }
  if ((navigator.appName == "Microsoft Internet Explorer") && (parseInt(navigator.appVersion)<3)) {
   top.name="principale"
  }	
  if (navigator.appVersion.indexOf("(X11") != -1 || navigator.appVersion.indexOf("(Mac") != -1) {
   nouvelle_fenetre=window.open(url,'', winOpts)
  }
  if (navigator.appName == "Netscape" && (parseInt(navigator.appVersion) >=3 )) {
   nouvelle_fenetre.focus()
  }
 }
}

function ouvrirPhotoG(url,x,y) {
 if (url != "") {
  x=x+18
  y=y+23
  var MinWin, winOpts="width="+x+",height="+y+",resizable=yes,scrollbars=yes,toolbar=no,location=no,directories=no,status=no"
  if (((navigator.appName == "Microsoft Internet Explorer") && (parseInt(navigator.appVersion)>3)) || (navigator.appName == "Netscape")) {
   pere=top
  }
  nouvelle_fenetre=window.open(url,'', winOpts)  
  if (((navigator.appName == "Microsoft Internet Explorer") && (parseInt(navigator.appVersion)>3)) || (navigator.appName == "Netscape")) {
   nouvelle_fenetre.pere=pere
  }
  if ((navigator.appName == "Microsoft Internet Explorer") && (parseInt(navigator.appVersion)<3)) {
   top.name="principale"
  }	
  if (navigator.appVersion.indexOf("(X11") != -1 || navigator.appVersion.indexOf("(Mac") != -1) {
   nouvelle_fenetre=window.open(url,'', winOpts)
  }
  if (navigator.appName == "Netscape" && (parseInt(navigator.appVersion) >=3 )) {
   nouvelle_fenetre.focus()
  }
 }
}

function ouvrirFenetre(url,x,y) {
 if (url != "") {
  x=x+18
  y=y+23
  var winOpts="width="+x+",height="+y+",resizable=yes,scrollbars=yes,toolbar=yes,location=yes,directories=yes,status=yes"
  nouvelle_fenetre=window.open(url,'', winOpts)  
 }
}

function ouvrirFenetreCentree(mypage,myname,w,h,scroll) {
 var win
 LeftPosition=(screen.width) ? (screen.width-w)/2 : 0
 TopPosition=(screen.height) ? (screen.height-h)/2 : 0
 settings='height='+h+',width='+w+',top='+TopPosition+',left='+LeftPosition+',scrollbars='+scroll+',resizable'
 win=window.open(mypage,myname,settings)
}

function reload() {
 history.go(0)
}

function proteger() {
 alert('Tous droits réservés, 1999-2000 ©\ngroupe I.S.D.O. - www.isdo.net')
 return false
}

function SetCookie (name, value) {
 var argv = SetCookie.arguments;
 var argc = SetCookie.arguments.length;
 var expires = (argc > 2) ? argv[2] : null;
 var path = (argc > 3) ? argv[3] : null;
 var domain = (argc > 4) ? argv[4] : null;
 var secure = (argc > 5) ? argv[5] : false;
 document.cookie = name + "=" + escape (value) +
 ((expires == null) ? "" : ("; expires=" + expires.toGMTString())) +
 ((path == null) ? "" : ("; path=" + path)) +
 ((domain == null) ? "" : ("; domain=" + domain)) +
 ((secure == true) ? "; secure" : "");
}

function GetCookie (name) {
 var arg = name + "=";
 var alen = arg.length;
 var clen = document.cookie.length;
 var i = 0;
 while (i < clen) {
	 var j = i + alen;
	 if (document.cookie.substring(i, j) == arg)
	 return getCookieVal (j);
 i = document.cookie.indexOf(" ", i) + 1;
 if (i == 0) break;
 }
 return null;
}

function getCookieVal (offset) {
 var endstr = document.cookie.indexOf (";", offset);
 if (endstr == -1)
 endstr = document.cookie.length;
 return unescape(document.cookie.substring(offset, endstr));
}

defaultStatus='www.PassionWebmaster.com'

var isNS=(navigator.appName == "Netscape" && parseInt(navigator.appVersion) >= 4)
var HIDDEN=(isNS) ? 'hide' : 'hidden';
var VISIBLE=(isNS) ? 'show' : 'visible';
var isMAC=(navigator.appVersion.indexOf("Mac")!=-1)
var lieuHebergement=document.location.toString()

var dxR=0,dyR=0

if (lieuHebergement.substring(0,7)=="http://") {
 peopleChoice=new Image();peopleChoice.src="http://www.peoplechoice.net/cgi-bin/picturechoice.pl?ID=14348"
}

var messageTitre="«Passion Webmaster»... le livre"
var neonbasecolor="black"
var neontextcolor="lime"
var flashspeed=100

var n=0

function neon() {
 if (n==0) {
  for (m=0;m<messageTitre.length;m++)
   tempref[m].style.color=neonbasecolor
 }
 tempref[n].style.color=neontextcolor
 if (n<tempref.length-1) {
  n++
 }
 else {
  n=0
  clearInterval(flashing)
  setTimeout("beginneon()",1500)
  return
 }
}

function beginneon(){
 if (document.all)
  flashing=setInterval("neon()",flashspeed)
}