ieHover = function() {
	var ieEl = document.getElementById("menu").getElementsByTagName("LI");
	for (var i=0; i<ieEl.length; i++) {
		ieEl[i].onmouseover=function() {
		
			this.className+=" iehover";
		}
		ieEl[i].onmouseout=function() {
			
			this.className=this.className.replace(new RegExp(" iehover\\b"), "");
			
		}
	}
}

var scrlStr = " +  Auspuff  +  Bremsen  +  Stoßdämpfer  +  Inspektion  +  Ölwechsel  +  Abgasuntersuchungen  +  Hauptuntersuchung gemäß §29  +  Katalysatoren  +  Schweißarbeiten  +  Kupplungen  +  Autoglas  +  Reifen                                .... und mehr "+
"                                                                                                           ";
function scroll()
{
  len = scrlStr.length;
  var scroll = "";
  scroll = scrlStr.substring(1, len)+ scrlStr.substring(0,1);
  window.status = scroll;
  scrlStr = scroll;
  setTimeout("scroll()",300);     // schrittgeschwindigkeit 0.1 sek
}
function Fenster(v_bild)
{
	var w_screen	= screen.width;
   	var window_width	= 820;
   	var window_height	= 640;
   	if (v_bild!=0)
   	{
		window_width-= 37;
		window_height-= 113;
	}
	var param;
	switch (w_screen)
   	{
		case 800:
			window_width  = window_width/1.28;
			window_height = window_height/1.28;
		break;
		case 640:
			window_width = window_width/1.6;
			window_height = window_height/1.6;
		break;
	}
	if (v_bild==0)
   	{
		param='resizable=yes,status=0,toolbar=no,scrollbars=yes,width='+window_width+',height='+window_height;
		var index = window.open("Seiten/angebot.php","test",param);
	}
 	else
 	{
		param='height='+window_height+',width='+window_width+', toolbar=no, menubar=no, scrollbars=no, resizable=no,location=no, directories=no, status=no'
		var index = window.open("php/bild.php?bild="+v_bild+"&res="+w_screen,"test",param);	
	}
	index.moveTo(2,2);
}

function SetObj(c_obj,c_value,b_Visible,c_valuename)
{ 
	var obj;
	obj = document.getElementById(c_obj);
	if (c_valuename==0 && c_value!=0 )
		obj.innerHTML = c_value;
	else 
		{
			if(c_valuename == "src")
			{
				obj.src = c_value;
				obj.alt	= "";			
			}
		}	
	if (b_Visible == 0)
		obj.style.visibility = "hidden";
	else
		obj.style.visibility = "visible";
}
function TALen(t)
{
	var max=250, text;
	text = t.value;
	obj = document.getElementById('zmax');
	if (text.length > max)
	{
		alert('maximal '+max+' Zeichen erlaubt');
		t.value=text.substring(0,max);
		t.blur();
	}
	obj.innerHTML = 'noch '+(max - t.value.length)+' Zeichen';
}