//

function noError()
{
  return 0;
}

window.onerror = noError;

function mkblue(img, on, prefix)
{
  if (!prefix) prefix = "";
  if (parent.frames.links && parent.frames.links.document) {
    obj = parent.frames.links.document[img];
    if (obj) {
      if (on == 2) obj.src = prefix + "images/knopfdauer.gif";
      if (on == 3) obj.src = prefix + "images/knopfblau.gif";
      if (on < 2)
        if (obj.src.indexOf("dauer") == -1)
          obj.src = prefix + "images/knopf" + (on?"tuerkis":"blau") + ".gif";
    }
  }
}

// Macromedia Fireworks 2.0

/* Function that swaps images. */
function di20(id, newSrc) {
    var theImage = FWFindImage(document, id, 0);
    if (theImage) {
        theImage.src = newSrc;
    }
}

/* Functions that track and set toggle group button states. */
function FWFindImage(doc, name, j) {
    var theImage = false;
    if (doc.images) {
        theImage = doc.images[name];
    }
    if (theImage) {
        return theImage;
    }
    if (doc.layers) {
        for (j = 0; j < doc.layers.length; j++) {
            theImage = FWFindImage(doc.layers[j].document, name, 0);
            if (theImage) {
                return (theImage);
            }
        }
    }
    return (false);
}

// eigene Funktionen

function gotoHomepage()
{
  if (top.frames.length == 0) then
    top.document.src = document.src;
}

function loadInFrame(framename, url)
{
  if (top.frames[framename]) {
    top.frames[framename].location = url;
  }
}

// Presse

function presse(link)
{
  if (document.pressefenster) {
    if (!document.pressefenster.closed)
      document.pressefenster.close();
    document.pressefenster = null;
  }
  document.pressefenster = 
    window.open('presse/' + link + '.html', 'artikel',
      'height=300,width=400,scrollbars');
}

