function DATABASES_LIST() { $q = new mysql(); $array = $q->DATABASE_LIST(); if (!is_array($array)) { return MYSQL_NO_CONNECTIONS($q); } $html = "<table style='width:100%'>\n\t<tr>\n\t\t<th> </th>\n\t\t<th>{database}</th>\n\t\t<th>{tables_number}</th>\n\t\t<th>{database_size}</th>\n\t</tr>"; while (list($num, $ligne) = each($array)) { if ($ligne[0] == null) { $ligne[0] = "0"; } $js = "LoadMysqlTables('{$num}');"; $html = $html . "<tr " . CellRollOver($js) . ">\n\t\t<td width=1%><img src='img/fw_bold.gif'></td>\n\t\t<td width=1% nowrap><code style='font-size:12px;font-weight:bold'>{$num}</code></td>\n\t\t<td width=1% nowrap><code style='font-size:12px;font-weight:bold'>{$ligne[0]}</code></td>\n\t\t<td width=80% nowrap><code style='font-size:12px;font-weight:bold'>{$ligne[1]}</code></td>\n\t\t</tr>"; } $html = $html . "</table>"; return $html; }
function DATABASES_LIST() { $q = new mysql(); $array = $q->DATABASE_LIST(); if (!is_array($array)) { return MYSQL_NO_CONNECTIONS($q); } $html = "<table cellspacing='0' cellpadding='0' border='0' class='tableView' style='width:100%'>\n<thead class='thead'>\n\t<tr>\n\t\t<th> </th>\n\t\t<th>{database}</th>\n\t\t<th>{tables_number}</th>\n\t\t<th>{database_size}</th>\n\t</tr>\n</thead>\n<tbody class='tbody'>"; while (list($num, $ligne) = each($array)) { if ($classtr == "oddRow") { $classtr = null; } else { $classtr = "oddRow"; } if ($ligne[0] == null) { $ligne[0] = "0"; } $js = "LoadMysqlTables('{$num}');"; $html = $html . "\n\t\t<tr class={$classtr}>\n\t\t\t<td width=1%><img src='img/datasource-32.png'></td>\n\t\t\t<td width=1% nowrap><a href=\"javascript:blur();\" OnClick=\"{$js}\" style='font-size:16px;font-weight:bold;text-decoration:underline'>{$num}</code></td>\n\t\t\t<td width=1% nowrap><code style='font-size:16px;font-weight:bold'>{$ligne[0]}</code></td>\n\t\t\t<td width=80% nowrap><code style='font-size:16px;font-weight:bold'>{$ligne[1]}</code></td>\n\t\t</tr>"; } $html = $html . "\n\t</tbody>\n\t</table>"; return $html; }