<!--
function openWindow(theURL, winName, features) {
  window.open(theURL, winName, features);
  return false;
}
function getLocation() {
  var str = document.cookie;
  var location = "/ephemerides/ephemerides.php";
  // verifier les cookies
  if (str != "") {
    var strarray = str.split(";");
    for (i = 0; i < strarray.length; i++) {
      var pivot = strarray[i].split("=");
      while ('' + pivot[0].charAt(0) == ' ') {
        pivot[0] = pivot[0].substring(1, pivot[0].length);
      }
      // alert("debug: pivot[0]=" + pivot[0]);
      if (pivot[0] == "tdm.ephUnique" && pivot[1] == 1) {
        // la location devrait etre alors ephemerides.php?unique=1
        location = location + "?unique=1";
      }
      else if (pivot[0] == "tdm.ephOnce") {
        // la fenetre est deja affiche aujourd'hui, on ne veut plus l'afficher
        // de nouveau, vu que l'usager en a decide ainsi :-)
        location = "";
      }
    }
  }
  return location;
}
function getEphemerides() {
  var location = getLocation();
  // lancer la fenetre des ephemerides si et seulement si l'usager en veut
  if (location != "") {
    // alert("debug: location=" + location);
    openWindow(location,
               'ephemerides',
               'scrollbars=yes, width=463, height=400, title=no, status=no, toolbar=no, menubar=no, location=no, resizable=yes');
  }
}
function popupEphemerides() {
  openWindow('/ephemerides/ephemerides.php',
             'ephemerides',
             'scrollbars=yes, width=463, height=400, title=no, status=no, toolbar=no, menubar=no, location=no, resizable=yes');
}
function displayEphemerides() {
  var location = getLocation();
  // lancer la fenetre des ephemerides si et seulement si l'usager en veut
  if (location != "") {
    self.location = location;
  }
}
//-->

