<?
########## Confixx(R) 3.0 Professional ############
####### Copyright SWsoft, Inc. 2004-2005 ##########
#### http://www.sw-soft.com - info@sw-soft.com ####

include_once( "../include/class.SQLString.php" );
include_once("auth.php");

db_connect($db_host, $db_user, $db_pass);

$id = safe_query( "select frontpage, cssl, maxmysql, dbext from anbieter where anbieter = ? ", TRUE, new SQLString( $PHP_AUTH_USER ) );
$werte = db_fetch_array($id);
$skfrontpage = $werte["frontpage"];
$skssl = $werte["cssl"];
$skdbext = $werte["dbext"];
$maxmysql = $werte["maxmysql"];
if ($maxmysql != 0) $skmysql = 1;

$id = safe_query( "select * from mysql_datenbanken where anbieter = ? ", TRUE, new SQLString( $PHP_AUTH_USER ) );
while ($werte = db_fetch_array($id))
	{
	 $index = str_replace($user_prefix, "", $werte["kunde"]);
	 $tabelle[$index][$werte["datenbank"]] = $werte["dbext"];
	}
?>
<HTML>
<HEAD>
<META content="text/html; charset=<? echo $lang_html_charset; ?>" http-equiv=Content-Type>
<LINK href="<?=$strSkinName?>/style.css" rel=stylesheet type=text/css>
</HEAD>

<BODY bgColor=#ffffff bottomMargin=0 leftMargin=0 topMargin=0 MARGINHEIGHT="0" MARGINWIDTH="0">
<br><? include("../fehler.inc.php"); ?>
<script>
function doChange()
{
document.forms[0].submit();
}
</script>
<table class="tblbgcolor" align="left" border="1" cellpadding="3" cellspacing="0" bordercolorlight="#CCCCCC" bordercolordark="#FFFFFF">
<tr>

    <TD height="176" valign="top"> 
      <? if ($skdbext == 1) { ?>
      <p>
       
        <? echo ltext("kumy_descr2"); ?>
        </p>
      <? } else { ?>
      <p>
       
        <? echo ltext("kumy_descr3"); ?>
        </p>
      <? } ?>
      <table border="1" cellpadding="3" cellspacing="0" bordercolorlight="<? echo $color_dark_grey; ?>" bordercolordark="#FFFFFF">
        <tr > 
          <td  class="titel-3" >
            <? echo ltext("kumy_cell_user"); ?>
            </td>
          <td class="titel-3" > 
            <div align="center">
              <? echo ltext("kumy_cell_db"); ?>
              </div>
          </td>
          <td class="titel-3" >
            <div align="center">
              <? echo ltext("kumy_cell_ext"); ?>
              </div>
          </td>
        </tr>
        <?
if (is_array($tabelle))	{
ksort($tabelle);
while (list ($kunde, $datenbanken) = each ($tabelle))
	{
	 ksort($datenbanken);
	 $kundenstr = $user_prefix.$kunde;
	 while (list ($datenbank, $dbext) = each ($datenbanken))
		{
		 $datenbankstr = "usr_".$kundenstr."_".$datenbank;
		 if ($dbext == 1) $dbextlink = ltext("kumy_cell_true"); else $dbextlink = ltext("kumy_cell_false");
		 if ($skdbext == 1) $dbextlink = '<a class=data href="kunden_mysql_dbext.php?dbname='.$datenbankstr.'">'.$dbextlink.'</a>';
?>
        <tr > 
          <td>
            <? echo $kundenstr; ?>
            </td>
          <td >
            <? echo $datenbankstr; ?>
            </td>
          <td>
            <? echo $dbextlink; ?>
            </td>
        </tr>
        <?
		}
	}
}
?>
      </table>
    </TD>
  </TR>
</TABLE>
</BODY>
</HTML>

<?
db_close();
?>
