﻿// JavaScript für Menu-Steuerung
  var item = new Array("Pr&auml;parate",
                       "Synthetikfelsen",
                       "Kopfformen",
                       "Zubeh&ouml;r",
                       "Preislisten",
                       "Kontakt")

  var link = new Array("../praeparate/index.html",
                       "../felsen/index.html",
                       "../kopfformen/index.html",
                       "../zubehoer/index.html",
                       "../preislisten/index.html",
                       "../kontakt/index.html")

  var selection=-1;
  
  function MouseOver(id) {
    if (id != selection) {
      document.getElementById(id).className = 'hilight';
    }  
  }
  
  function MouseOut(id) {
    if (id != selection) {
      document.getElementById(id).className = 'standard';
    }
  }
  
  function Click(id){
    if (selection > -1) {
      document.getElementById(selection).className = 'standard';
    }  
    document.getElementById(id).className = 'active';
    parent.mainFrame.location.href = link[id];
    selection = id;
  }

  for (var i=0; i< item.length; i++) {
    if (i != 0) {
		document.write("<tr>");
		document.write("<td height='5' align='center'><img src='menu_line.gif'></td>");
		document.write("</tr>");
	}
    document.write("<tr>");
    document.write("<td height='33' class='standard' id='" + i + "' " +
                   "onMouseOver='MouseOver(" + i + ")' " +
                   "onMouseOut='MouseOut(" + i + ")' " +
                   "onClick='Click(" + i + ")'><a href='" + link[i] + 
                   "' target='mainFrame'>" + item[i] + 
                   "</a></td>");
    document.write("</tr>");
  }



