  function delitem()
  {
  alert("input");
  //w = window.open("insert2.asp?func=delete&itemid="+input,"w","scrollbars=no,resizable=yes,width=100,height=100, left=400,top=50");
  //if(w.opener == null) w.opener = window;w.focus();
  }

  function showbasket(sid)
{
//OnClick="javascript:fktshowbasket('<% = sid %>');"
//alert("Test");
top.inhalt.document.location.href="merkliste.asp?sid="+sid;
//parent.inhalt.location.href="merkliste_short.asp?sid="+sid;
}

function produkte()
{
parent.location.href="index.asp";
//parent.menu.location.href="menu_pdm.asp";
//parent.menu_sec.location.href="menu_sec_pro.asp";
//parent.inhalt.location.href="produktdesmonats.asp";
}

function suche()
// wird aufgerufen im Menü menu_pdm.asp
{
parent.location.href="index.asp?func=suche";

//parent.menu.location.href="menu_suc.asp";
//parent.menu_sec.location.href="leer.asp";
//parent.inhalt.location.href="suchmaske.asp";
}

function kontakt()
// wird aufgerufen im Menü menu_pdm.asp
{
parent.location.href="index.asp?func=kontakt";
//parent.menu.location.href="menu_kon.asp";
//parent.menu_sec.location.href="partnerlink.asp";
//parent.inhalt.location.href="kontakt.asp";
}

function myproject()
{
parent.menu.location.href="menu_pwg.asp";
parent.menu_sec.location.href="menu_sec_pro.asp";
parent.inhalt.location.href="leer.asp";
}

function trpwgClick(wgid)
{
parent.menu.location.href="menu_pwg.asp?wgid="+wgid;
parent.inhalt.location.href="produkte.asp?wgid="+wgid;
}

function menuClick(obj,wgid,sessionwgid)
{
alert('f');
 for (i=2; i < document.getElementsByTagName('tbody').length; i++)
        document.getElementsByTagName('tbody')[i].childNodes[0].bgColor = "#d1d1d1";
 obj.getElementsByTagName('td')[0].parentNode.bgColor = "#ff9600";
// parent.menu.location.href="menu_pwg.asp?wgid="+wgid;
// parent.menu_sec.location.href="menu_sec_pro.asp?wgid="+wgid;
 parent.inhalt.location.href="produkte.asp?wgid="+wgid;
 document.form1.kurzbezeichnung.value = 'Schnellsuche';
}

function menu0Click(obj,katid,wgid)
// wird von der Orangen und Grauen Kategorie aufgerufen, beim Klicken bleibt die Hintergrundfarbe d-grau
{

 for (i=2; i < document.getElementsByTagName('tbody').length; i++)
        document.getElementsByTagName('tbody')[i].childNodes[0].bgColor = "#d1d1d1";
 obj.getElementsByTagName('td')[0].parentNode.bgColor = "#AAAAAA";
 parent.menu_sec.location.href="menu_sec_pro.asp?katid="+katid+"&wgid="+wgid;
 parent.menu.location.href="menu_pwg.asp?katid="+katid+"&wgid="+wgid;
 parent.inhalt.location.href="leer.asp";
 document.form1.kurzbezeichnung.value = 'Schnellsuche';
}

function menu1Click(obj,katid,wgid)
// wird von der grauen Kategorie aufgerufen, beim Klicken wird die Hintergrundfarbe KURZ h-grau
{

 for (i=2; i < document.getElementsByTagName('tbody').length; i++)
        document.getElementsByTagName('tbody')[i].childNodes[0].bgColor = "#d1d1d1";
 obj.getElementsByTagName('td')[0].parentNode.bgColor = "#d1d1d1";
 parent.menu.location.href="menu_pwg.asp?katid=0&wgid="+wgid;
 parent.menu_sec.location.href="menu_sec_pro.asp?katid="+katid+"&wgid="+wgid;
 parent.inhalt.location.href="produkte.asp?wgid="+wgid;
 document.form1.kurzbezeichnung.value = 'Schnellsuche';
}

function menu2Click(obj,katid,wgid)
// wird von der grauen Warengruppe aufgerufen, nach dem Klicken bleibt die Hintergrundfarbe ORANGE
// es wird nur die Warengruppe im Ober-Menü eingestellt, die Menü_sec wird nicht aktualisiert
{
 for (i=2; i < document.getElementsByTagName('tbody').length; i++)
 {
     if (document.getElementsByTagName('tbody')[i].childNodes[0].bgColor != "#aaaaaa")
        {
        document.getElementsByTagName('tbody')[i].childNodes[0].bgColor = "#d1d1d1";
        }
 }
 obj.getElementsByTagName('td')[0].parentNode.bgColor = "#ff9600";
 parent.menu.location.href="menu_pwg.asp?katid=0&wgid="+wgid;
 parent.inhalt.location.href="produkte.asp?wgid="+wgid;
 document.form1.kurzbezeichnung.value = 'Schnellsuche';
}

function menu3Click(obj,katid,wgid)
// wird von der Orangen und Grauen Kategorie (Direktkategorie, Leaf = False) aufgerufen, beim Klicken bleibt die Hintergrundfarbe orange
{

 for (i=2; i < document.getElementsByTagName('tbody').length; i++)
        document.getElementsByTagName('tbody')[i].childNodes[0].bgColor = "#d1d1d1";
 obj.getElementsByTagName('td')[0].parentNode.bgColor = "#ff9600";
 parent.menu_sec.location.href="menu_sec_pro.asp?katid="+katid+"&wgid="+wgid;
 parent.menu.location.href="menu_pwg.asp?katid=0&wgid="+wgid;
// parent.menu.location.href="menu_pwg.asp?katid="+katid+"&wgid="+wgid;
 parent.inhalt.location.href="produkte.asp?wgid="+wgid;
// parent.inhalt.location.href="leer.asp";
 document.form1.kurzbezeichnung.value = 'Schnellsuche';
 // document.form1.kurzbezeichnung.value = 'katid='+katid;
}

function menu3aClick(obj,katid,wgid)
// wird von der Orangen und Grauen Kategorie (Direktkategorie, Leaf = False) aufgerufen, beim Klicken bleibt die Hintergrundfarbe orange
// überarbeitet 17/9/06 -> das doppelte Clicken soll zumindest damit bei der Direktkategorei verschwinden
{
 for (i=2; i < document.getElementsByTagName('tbody').length; i++)
        document.getElementsByTagName('tbody')[i].childNodes[0].bgColor = "#d1d1d1";
 obj.parentNode.parentNode.bgColor = "#ff9600";
// parent.menu_sec.location.href="menu_sec_pro.asp?katid="+katid+"&wgid="+wgid;
// parent.menu.location.href="menu_pwg.asp?katid=0&wgid="+wgid;
 document.form1.kurzbezeichnung.value = 'Schnellsuche';
 // document.form1.kurzbezeichnung.value = 'katid='+katid;
}


function linkClick()
{
 for (i=2; i < document.getElementsByTagName('tbody').length; i++)
        document.getElementsByTagName('tbody')[i].childNodes[0].bgColor = "#d1d1d1";
}

function trpdmClick()
{
parent.inhalt.location.href="produktdesmonats.asp";
}

function GoBack()
{
// für Showdetail (ohne Frames) zurück
  history.back();
}

function iframesBack(F1,F2) {
  Frame1=eval("parent."+F1);
  Frame2=eval("parent."+F2);
  Frame1.history.go(-1);
  if (!window.opera) window.setTimeout("Frame2.history.back()",10);
}

function suchiframesBack(F1,F2) {
  Frame1=eval("parent."+F1);
  Frame2=eval("parent."+F2);
  Frame1.history.go(-1);
  Frame2.history.go(-1);
  if (!window.opera) window.setTimeout("Frame2.history.back()",10);
}

function setColor_submenu(obj)
{
  var elements;
  if(document.all)elements=document.all;
  else if(document.getElementsByTagName && !document.all)elements=document.getElementsByTagName("*");

  for(i=0;i<elements.length;i++)
  {
    if(elements[i].getAttribute("id") == "current" && elements[i].getAttribute("id") != "")elements[i].id="";
  }
  obj.id="current"
}

function setColor(obj, x, y)
{
        if (obj.getElementsByTagName('td')[0].parentNode.bgColor == "#d1d1d1")
        {
                 obj.getElementsByTagName('td')[0].parentNode.bgColor = "#aaaaaa";
        }
        else
        {
                if (obj.getElementsByTagName('td')[0].parentNode.bgColor == "#aaaaaa")
                {
                obj.getElementsByTagName('td')[0].parentNode.bgColor = "#d1d1d1";
                }
        }
}

function getEmail(input)
{
if (input == 1)	 
return 'E-Mail: <a href="mailto:info@yellow-werbemittel.de" class="text09">info(at)yellow-werbemittel.de</a>';
else if (input==2)
return '<img src="images/1x1.gif" width="10" height="1" border="0"><a href="mailto:mantel@yellow-werbemittel.de" class="text08">rm(at)yellow-werbemittel.de</a>';
else if (input==3)
return '<img src="images/1x1.gif" width="10" height="1" border="0"><a href="mailto:palescak@yellow-werbemittel.de" class="text08">sp(at)yellow-werbemittel.de</a>';
else if (input==4)
return '<img src="images/1x1.gif" width="10" height="1" border="0"><a href="mailto:rm@yellow-werbemittel.de" class="text08">bs(at)yellow-werbemittel.de</a>';


}
