//Robby Jansch
//js-lib.js
//all the general-functions for this project
//29.04.05
function pic_change(id){
	window.document.picture.src="nothing.gif";
}
/*
//get all the screeninfos you need
function screeninfo(){
//fits on all browsers
alert("Bildschirm:" + screen.width + " x " + screen.height);
//fits only on IE - the others take window.innerwidth
alert("Fenster:" +  document.body.offsetWidth  + " x " + document.body.offsetHeight );
//extend it  with screen infos 

}


//to get the actual position of the mouse 
//put this into the html, onload="init_mousemove()"
//<form style="position:absolute;top:0px;left:200px" name="feld"><input type="text" name="ausg"></form>
//
// find out if ie runs in quirks mode
//
var docEl = (
             typeof document.compatMode != "undefined" && 
             document.compatMode        != "BackCompat"
            )? "documentElement" : "body";

// register event
// capture it for nc 4x (ok it's a dino)
//
function init_mousemove() {
    if(document.layers) document.captureEvents(Event.MOUSEMOVE);
    document.onmousemove =	dpl_mouse_pos;
}

function dpl_mouse_pos(e) {

    // position where mousemove fired
    //
    var xPos    =  e? e.pageX : window.event.x;
	var yPos    =  e? e.pageY : window.event.y;

	
	// for ie add scroll position
	//
	if (document.all && !document.captureEvents) {
	    xPos    += document[docEl].scrollTop;
	    yPos    += document[docEl].scrollTop;
    }
    
    // display position
    //
    document.feld.ausg.value    =  "Left = " + xPos + " : Top = " + yPos;
    
    // for the dino pass event
    //
    if (document.layers) routeEvent(e);
}



//testfunction - leave it on the end
function DHTMLtest() {
  var Ausgabetext = "";
  if (DHTML) {
    Ausgabetext += "DHTML ist aktiviert!\n"
  } else {
    Ausgabetext += "DHTML ist nicht aktiviert!\n";
  }
  if (DOM) {
    Ausgabetext += "DOM wird unterstützt!\n";
  } else {
    Ausgabetext += "DOM wird nicht unterstützt!\n";
  }
  if (MSIE4)
    Ausgabetext += "Alte Microsoft-Technologie ohne DOM!\n";
  if (NS4)
    Ausgabetext += "Alte Netscape-Technologie ohne DOM!\n";

  /*var h1_Inhalt = getContent("tagname", "h1", 0);
  if (h1_Inhalt) {
    Ausgabetext += "Inhalt des h1-Elements: " + h1_Inhalt + "!\n";
  } else {
    Ausgabetext += "Inhalt des h1-Elements konnte nicht ermittelt werden!\n";
  }*/

  /*var p_Inhalt = getContent("id", "Hinweisabsatz", null);
  if (p_Inhalt) {
    Ausgabetext += "Inhalt des p-Elements: " + p_Inhalt + "!\n";
  } else {
    Ausgabetext += "Inhalt des p-Elements konnte nicht ermittelt werden!\n";
  }*/

  /*if (NS4) {
    Verweis = getAttribute("name", "anchors", "Anker", "text");
  } else {
    Verweis = getContent("name", "Anker", 0);
  }
  if (Verweis) {
    Ausgabetext += "Verweistext: " + Verweis + "!\n";
  } else {
    Ausgabetext += "Verweistext konnte nicht ermittelt werden!\n";
  }*/

 /* var h1_align = getAttribute("tagname", "h1", 0, "align");
  if (h1_align) {
    Ausgabetext += "Ausrichtung des h1-Elements: " + h1_align + "!\n";
  } else {
    Ausgabetext += "Ausrichtung des h1-Elements konnte nicht ermittelt werden!\n";
  }*/

  /*var Bild_Hoehe= getAttribute("name", "auge", 0, "height");
  if (Bild_Hoehe) {
    Ausgabetext += "Bildhöhe: " + Bild_Hoehe + "px.\n";
  } else {
    Ausgabetext += "Die Bildhöhe konnte nicht ermittelt werden!\n";
  }*/

  /*var Bereich_id = getAttribute("id", "Bereich", null, "id");
  if (Bereich_id) {
    Ausgabetext += "id-Name des Bereichs: " + Bereich_id + "!\n";
  } else {
    Ausgabetext += "id-Name des Bereichs konnte nicht ermittelt werden!\n";
  }

  setContent("id", "Bereich", null, "Tests sind fertig!");

  alert(Ausgabetext);
}

*/
