function get_con(cid, pid, seite_neu, max, modus, spalte) {

  var xmlHttp_mc = false;

  try {xmlHttp_mc  = new ActiveXObject("Msxml2.XMLHTTP");}

  catch(a_mc) {
    try {
      xmlHttp_mc  = new ActiveXObject("Microsoft.XMLHTTP");
    } catch(a_mc) {
      xmlHttp_mc  = false;
    }
  }

  if (!xmlHttp_mc  && typeof XMLHttpRequest != "undefined" ) {  // nicht IE
    xmlHttp_mc = new XMLHttpRequest();
  }

  if (xmlHttp_mc) {

    width = spalte == "_r" ? 350 : 768;

    var div = "multi_con"+spalte;

    div = document.getElementById(div);
    //spalte = "_r";

    var div2 = "multi_con2"+spalte;
    // alert(div2);
    div2 = document.getElementById(div2);

    xmlHttp_mc.open("GET", "pages/catch_con.php?cid="+cid+"&seite="+seite_neu+"&max="+max+"&modus="+modus+"&spalte="+spalte, true);

    seite_zurueck = seite_neu - 1 == 0 ? max : seite_neu - 1;
    seite_weiter  = seite_neu + 1 > max ? 1 : seite_neu + 1;
    /*if (modus == 1)
      if (seite >= max)
        seite = 1;
      else
        seite++;
    else {
      alert(seite);
      if (seite < 1)
        seite = max;
      else
        seite--;
    }*/
//alert("seite_zurueck:"+seite_zurueck+" - seite_neu:"+seite_neu+" - seite_weiter:"+seite_weiter);
    xmlHttp_mc.onreadystatechange = function () {

    var html_neu = "";

      if (xmlHttp_mc.readyState == 4) {
        var ergebnis = xmlHttp_mc.responseText;
        var einzel_mc = ergebnis.split("\n");

        //var max_seiten = 1;
       // if (typeof(content) != "undefined") {

          for (i=0; i<einzel_mc.length; i++) {
            content = einzel_mc[i].split("###");

            //alert(modus);
            if (content[0] != "") {
              if (typeof(content) != "undefined")
                html_neu = html_neu+'<td width="33%" style="background-color:#ffffff; background-image: url(./img/ds_bg.gif); background-repeat:repeat-x;" align="left" valign="top"><table cellspacing="0" height="40"><tr><td valign="top"><a href="./default.php?d=cont&pid='+content[2]+'&cid='+content[0]+'" style="font-weight:bold; color:#395498; text-decoration:none">'+unescape(content[3])+'</a></td></tr></table><a href="./default.php?d=cont&pid='+content[2]+'&cid='+content[0]+'">'+unescape(content[1])+'</a></td>';
            }

            //if (i == 1)
            //  max_seiten = content[3];
          }
          if (html_neu != '') {
            div.innerHTML = '<table border=0 cellspacing="2" cellpadding="3" width="'+width+'" height="110"><tr>'+html_neu+'</tr></table>';
            //alert(seite);
            //alert(seite);

            var navi_neu = "";

            navi_neu = '<table border=0 width="'+width+'"><tr>';

            //alert(seite+" - "+max_seiten);

            //if (seite > 0)
            navi_neu = navi_neu+'<td align="left" width="50%"><span id="pfeil_l" title="zurück" style="cursor:pointer; background-image: url(./img/pfeil_ds_l.gif); width:97px; height:26px; display:block;" onMouseOver="pfeil(1, \'pfeil_l\', \'lo\')" onMouseOut="pfeil(0,\'pfeil_l\', \'l\')" onClick="get_con('+cid+', '+pid+', '+seite_zurueck+', '+max+', '+modus+', \''+spalte+'\')"></span></td><td align="right" width="50%"><span id="pfeil_r" title="vorwärts" style="cursor:pointer; background-image: url(./img/pfeil_ds_r.gif); width:97px; height:26px; display:block;" onMouseOver="pfeil(1,\'pfeil_r\', \'ro\')" onMouseOut="pfeil(0,\'pfeil_r\', \'r\')" onClick="get_con('+cid+', '+pid+', '+seite_weiter+', '+max+', '+modus+', \''+spalte+'\')"></span></td>';

            div2.innerHTML = navi_neu+'</tr></table>';
          }
       // }
      }
    }

    xmlHttp_mc.send(null);
  }
}

function pfeil(modus,element,richtung) {
  if (modus == 1)
    document.getElementById(element).style.backgroundImage = 'url(./img/pfeil_ds_'+richtung+'.gif)';
  else
    document.getElementById(element).style.backgroundImage = 'url(./img/pfeil_ds_'+richtung+'.gif)';
}  