// ===============================================================
// Javascripts Stiftung Wehrenbach
// date:     9.2.2002
// author:   Basil Gantenbein

//---- Snake-Images & Symbol Home
sn_logo = new Image(101,11); 
sn_logo.src = pathToRoot + "images/sn_logo.gif";
sn_logo_h1 = new Image(101,11); 
sn_logo_h1.src = pathToRoot + "images/sn_logo_h1.gif";
sn_logo_h2 = new Image(7,11); 
sn_logo_h2.src = pathToRoot + "images/sn_logo_h2.gif";
spacer = new Image(13,11); 
spacer.src = pathToRoot + "images/spacer.gif";
sn_logo_h3 = new Image(13,11);
sn_logo_h3.src = pathToRoot + "images/sn_logo_h3.gif";
sy_logo = new Image(46,37);
sy_logo.src = pathToRoot + "images/sy_logo.gif";

//---- Snake-Images & Symbol Stiftung
sn_stiftung = new Image(67,34); 
sn_stiftung.src = pathToRoot + "images/sn_stiftung.gif";
sn_stiftung_h = new Image(67,34);
sn_stiftung_h.src = pathToRoot + "images/sn_stiftung_h.gif";
sy_stiftung = new Image(46,37);
sy_stiftung.src = pathToRoot + "images/sy_stiftung.gif";
 
//---- Snake-Images & Symbol Wohnheime 
sn_wohnheime = new Image(67,37); 
sn_wohnheime.src = pathToRoot + "images/sn_wohnheime.gif";
sn_wohnheime_h = new Image(67,37);
sn_wohnheime_h.src = pathToRoot + "images/sn_wohnheime_h.gif";
sy_wohnheime = new Image(46,37);
sy_wohnheime.src = pathToRoot + "images/sy_wohnheime.gif";

//---- Snake-Images & Symbol Autismus 
sn_autismus = new Image(67,41); 
sn_autismus.src = pathToRoot + "images/sn_autismus.gif";
sn_autismus_h = new Image(67,41);
sn_autismus_h.src = pathToRoot + "images/sn_autismus_h.gif";
sy_autismus = new Image(46,37);
sy_autismus.src = pathToRoot + "images/sy_autismus.gif";
 
//---- Snake-Images & Symbol Produkte 
sn_produkte = new Image(67,41); 
sn_produkte.src = pathToRoot + "images/sn_produkte.gif";
sn_produkte_h = new Image(67,41);
sn_produkte_h.src = pathToRoot + "images/sn_produkte_h.gif";
sy_produkte = new Image(46,37);
sy_produkte.src = pathToRoot + "images/sy_produkte.gif";
 
//---- Snake-Images & Symbol Stellen 
sn_stellen = new Image(67,41); 
sn_stellen.src = pathToRoot + "images/sn_stellen.gif";
sn_stellen_h = new Image(67,41);
sn_stellen_h.src = pathToRoot + "images/sn_stellen_h.gif";
sy_stellen = new Image(46,37);
sy_stellen.src = pathToRoot + "images/sy_stellen.gif";
 
//---- Snake-Images & Symbol Spenden 
sn_spenden = new Image(67,41); 
sn_spenden.src = pathToRoot + "images/sn_spenden.gif";
sn_spenden_h = new Image(67,41);
sn_spenden_h.src = pathToRoot + "images/sn_spenden_h.gif";
sy_spenden = new Image(46,37);
sy_spenden.src = pathToRoot + "images/sy_spenden.gif";
 
//---- Snake-Images & Symbol Kontakt 
sn_kontakt = new Image(67,41); 
sn_kontakt.src = pathToRoot + "images/sn_kontakt.gif";
sn_kontakt_h = new Image(67,41);
sn_kontakt_h.src = pathToRoot + "images/sn_kontakt_h.gif";
sy_kontakt = new Image(46,37);
sy_kontakt.src = pathToRoot + "images/sy_kontakt.gif";
 
//---- Snake-Images & Symbol Links 
sn_links = new Image(67,40); 
sn_links.src = pathToRoot + "images/sn_links.gif";
sn_links_h = new Image(67,40);
sn_links_h.src = pathToRoot + "images/sn_links_h.gif";
sy_links = new Image(46,37);
sy_links.src = pathToRoot + "images/sy_links.gif";
  
// ------------------        imageflip        -------------------
// changes an image with another one
// INPUT:	ImageTagName	Name of the <img> Tag to change the image object
//			ImageObj	    ImageObject to show
// OUTPUT:  none 

function bildwechsel(ImageTagName, ImageObj)
  {
   eval("window.document."+ImageTagName+".src ="+ImageObj+".src");
  }
  
// ------------------        imageflip only IE      -------------------
// changes an image with another one, but only in Internet Explorer
// INPUT:	ImageTagName	Name of the <img> Tag to change the image object
//			ImageObj	    ImageObject to show
// OUTPUT:  none 

function bildwechsel_ie(ImageTagName, ImageObj)
  {
  if (window.document.all)
     eval("window.document."+ImageTagName+".src ="+ImageObj+".src");
  }  

// ------------------        background-exchange        -------------------
// changes the background of a table or td with another one
// INPUT:	TableTagName	Name of the table Tag to change the background
//			ImageUrl	    url of the image from the root directory
// OUTPUT:  none 

function bgchange(TableTagName, ImageUrl)
  {
   if (window.document.all)
	  eval("window.document.all."+TableTagName+".style.backgroundImage = \"url("+ImageUrl+")\"");
  }

  
// ------------------        new pop-up window        -------------------
// opens a new browser-window without menubar, locationbar etc.
// INPUT:	fileToOpen	    Name of the .html-file to be shown in the new window
//			windowName	    internal Name for the new window (to access the window in scripts etc.)
//			options			additional options for the window, see documentation of method open()
// OUTPUT:  none 

function newPopWin(fileToOpen, windowName, options)
  {
   NewPopupWin = window.open(fileToOpen, windowName, options);
   NewPopupWin.focus();
  }