fixed/cleaned printer output

This commit is contained in:
Sebastian Mendel
2006-02-17 11:05:56 +00:00
parent 2cecb832e6
commit fbb757bcfe

View File

@@ -1,32 +1,31 @@
<?php <?php
/* $Id$ */ /* $Id$ */
require_once('./libraries/common.lib.php'); require_once './libraries/common.lib.php';
/** /**
* Gets the variables sent or posted to this script, then displays headers * Gets the variables sent or posted to this script, then displays headers
*/ */
$print_view = TRUE; $print_view = true;
if (!isset($selected_tbl)) { if (! isset($selected_tbl)) {
require_once('./libraries/header.inc.php'); require_once './libraries/header.inc.php';
} }
// Check parameters // Check parameters
if (!isset($the_tables) || !is_array($the_tables)) { if (! isset($the_tables) || ! is_array($the_tables)) {
$the_tables = array(); $the_tables = array();
} }
/** /**
* Gets the relations settings * Gets the relations settings
*/ */
require_once('./libraries/relation.lib.php'); require_once './libraries/relation.lib.php';
require_once('./libraries/transformations.lib.php'); require_once './libraries/transformations.lib.php';
require_once('./libraries/tbl_indexes.lib.php'); require_once './libraries/tbl_indexes.lib.php';
$cfgRelation = PMA_getRelationsParam(); $cfgRelation = PMA_getRelationsParam();
/** /**
* Defines the url to return to in case of error in a sql statement * Defines the url to return to in case of error in a sql statement
*/ */
@@ -56,21 +55,21 @@ $multi_tables = (count($the_tables) > 1);
if ($multi_tables) { if ($multi_tables) {
if (empty($GLOBALS['is_header_sent'])) { if (empty($GLOBALS['is_header_sent'])) {
require_once('./libraries/header.inc.php'); require_once './libraries/header.inc.php';
} }
$tbl_list = ''; $tbl_list = '';
foreach ($the_tables AS $key => $table) { foreach ($the_tables as $key => $table) {
$tbl_list .= (empty($tbl_list) ? '' : ', ') $tbl_list .= (empty($tbl_list) ? '' : ', ')
. PMA_backquote(urldecode($table)); . PMA_backquote(urldecode($table));
} }
echo '<b>'. $strShowTables . ':&nbsp;' . $tbl_list . '</b>' . "\n"; echo '<b>'. $strShowTables . ': ' . $tbl_list . '</b>' . "\n";
echo '<hr />' . "\n"; echo '<hr />' . "\n";
} // end if } // end if
$tables_cnt = count($the_tables); $tables_cnt = count($the_tables);
$counter = 0; $counter = 0;
foreach ($the_tables AS $key => $table) { foreach ($the_tables as $key => $table) {
$table = urldecode($table); $table = urldecode($table);
if ($counter + 1 >= $tables_cnt) { if ($counter + 1 >= $tables_cnt) {
$breakstyle = ''; $breakstyle = '';
@@ -84,7 +83,8 @@ foreach ($the_tables AS $key => $table) {
/** /**
* Gets table informations * Gets table informations
*/ */
$result = PMA_DBI_query('SHOW TABLE STATUS LIKE \'' . PMA_sqlAddslashes($table, TRUE) . '\';'); $result = PMA_DBI_query(
'SHOW TABLE STATUS LIKE \'' . PMA_sqlAddslashes($table, true) . '\';');
$showtable = PMA_DBI_fetch_assoc($result); $showtable = PMA_DBI_fetch_assoc($result);
$num_rows = (isset($showtable['Rows']) ? $showtable['Rows'] : 0); $num_rows = (isset($showtable['Rows']) ? $showtable['Rows'] : 0);
$show_comment = (isset($showtable['Comment']) ? $showtable['Comment'] : ''); $show_comment = (isset($showtable['Comment']) ? $showtable['Comment'] : '');
@@ -102,7 +102,9 @@ foreach ($the_tables AS $key => $table) {
/** /**
* Gets fields properties * Gets fields properties
*/ */
$result = PMA_DBI_query('SHOW FIELDS FROM ' . PMA_backquote($table) . ';', null, PMA_DBI_QUERY_STORE); $result = PMA_DBI_query(
'SHOW FIELDS FROM ' . PMA_backquote($table) . ';', null,
PMA_DBI_QUERY_STORE);
$fields_cnt = PMA_DBI_num_rows($result); $fields_cnt = PMA_DBI_num_rows($result);
// Check if we can use Relations (Mike Beck) // Check if we can use Relations (Mike Beck)
@@ -112,12 +114,12 @@ foreach ($the_tables AS $key => $table) {
$res_rel = PMA_getForeigners($db, $table); $res_rel = PMA_getForeigners($db, $table);
if (count($res_rel) > 0) { if (count($res_rel) > 0) {
$have_rel = TRUE; $have_rel = true;
} else { } else {
$have_rel = FALSE; $have_rel = false;
} }
} else { } else {
$have_rel = FALSE; $have_rel = false;
} // end if } // end if
@@ -125,7 +127,7 @@ foreach ($the_tables AS $key => $table) {
* Displays the comments of the table if MySQL >= 3.23 * Displays the comments of the table if MySQL >= 3.23
*/ */
if (!empty($show_comment)) { if (!empty($show_comment)) {
echo $strTableComments . ':&nbsp;' . $show_comment . '<br /><br />'; echo $strTableComments . ': ' . $show_comment . '<br /><br />';
} }
/** /**
@@ -134,18 +136,18 @@ foreach ($the_tables AS $key => $table) {
?> ?>
<!-- TABLE INFORMATIONS --> <!-- TABLE INFORMATIONS -->
<table width="95%" bordercolorlight="black" border="border" style="border-collapse: collapse; background-color: white"> <table style="width: 100%;">
<thead>
<tr> <tr>
<th width="50"><?php echo $strField; ?></th> <th><?php echo $strField; ?></th>
<th width="80"><?php echo $strType; ?></th> <th><?php echo $strType; ?></th>
<!--<th width="50"><?php echo $strAttr; ?></th>--> <!--<th><?php echo $strAttr; ?></th>-->
<th width="40"><?php echo $strNull; ?></th> <th><?php echo $strNull; ?></th>
<th width="70"><?php echo $strDefault; ?></th> <th><?php echo $strDefault; ?></th>
<!--<th width="50"><?php echo $strExtra; ?></th>--> <!--<th><?php echo $strExtra; ?></th>-->
<?php <?php
echo "\n";
if ($have_rel) { if ($have_rel) {
echo ' <th>' . $strLinksTo . '</th>' . "\n"; echo '<th>' . $strLinksTo . '</th>' . "\n";
} }
if ($cfgRelation['commwork']) { if ($cfgRelation['commwork']) {
echo ' <th>' . $strComments . '</th>' . "\n"; echo ' <th>' . $strComments . '</th>' . "\n";
@@ -155,26 +157,22 @@ foreach ($the_tables AS $key => $table) {
} }
?> ?>
</tr> </tr>
</thead>
<tbody>
<?php <?php
$i = 0;
while ($row = PMA_DBI_fetch_assoc($result)) { while ($row = PMA_DBI_fetch_assoc($result)) {
$bgcolor = ($i % 2) ?$cfg['BgcolorOne'] : $cfg['BgcolorTwo'];
$i++;
$type = $row['Type']; $type = $row['Type'];
// reformat mysql query output - staybyte - 9. June 2001 // reformat mysql query output - staybyte - 9. June 2001
// loic1: set or enum types: slashes single quotes inside options // loic1: set or enum types: slashes single quotes inside options
if (preg_match('@^(set|enum)\((.+)\)$@i', $type, $tmp)) { if (preg_match('@^(set|enum)\((.+)\)$@i', $type, $tmp)) {
$tmp[2] = substr(preg_replace('@([^,])\'\'@', '\\1\\\'', ',' . $tmp[2]), 1); $tmp[2] = substr(preg_replace('@([^,])\'\'@', '\\1\\\'',
',' . $tmp[2]), 1);
$type = $tmp[1] . '(' . str_replace(',', ', ', $tmp[2]) . ')'; $type = $tmp[1] . '(' . str_replace(',', ', ', $tmp[2]) . ')';
$type_nowrap = '';
$binary = 0; $binary = 0;
$unsigned = 0; $unsigned = 0;
$zerofill = 0; $zerofill = 0;
} else { } else {
$type_nowrap = ' nowrap="nowrap"';
$type = preg_replace('@BINARY@i', '', $type); $type = preg_replace('@BINARY@i', '', $type);
$type = preg_replace('@ZEROFILL@i', '', $type); $type = preg_replace('@ZEROFILL@i', '', $type);
$type = preg_replace('@UNSIGNED@i', '', $type); $type = preg_replace('@UNSIGNED@i', '', $type);
@@ -204,34 +202,32 @@ foreach ($the_tables AS $key => $table) {
$row['Default'] = htmlspecialchars($row['Default']); $row['Default'] = htmlspecialchars($row['Default']);
} }
$field_name = htmlspecialchars($row['Field']); $field_name = htmlspecialchars($row['Field']);
echo "\n";
?> ?>
<tr>
<td width="50" class="print" nowrap="nowrap"> <tr><td>
<?php <?php
if (isset($pk_array[$row['Field']])) { if (isset($pk_array[$row['Field']])) {
echo ' <u>' . $field_name . '</u>&nbsp;' . "\n"; echo ' <u>' . $field_name . '</u>' . "\n";
} else { } else {
echo ' ' . $field_name . '&nbsp;' . "\n"; echo ' ' . $field_name . "\n";
} }
?> ?>
</td> </td>
<td width="80" class="print"<?php echo $type_nowrap; ?>><?php echo $type; ?><bdo dir="ltr"></bdo></td> <td><?php echo $type; ?><bdo dir="ltr"></bdo></td>
<!--<td width="50" bgcolor="<?php echo $bgcolor; ?>" nowrap="nowrap"><?php echo $strAttribute; ?></td>--> <!--<td><?php echo $strAttribute; ?></td>-->
<td width="40" class="print"><?php echo (($row['Null'] == '' || $row['Null'] == 'NO') ? $strNo : $strYes); ?>&nbsp;</td> <td><?php echo (($row['Null'] == '' || $row['Null'] == 'NO') ? $strNo : $strYes); ?>&nbsp;</td>
<td width="70" class="print" nowrap="nowrap"><?php if (isset($row['Default'])) { echo $row['Default']; } ?>&nbsp;</td> <td><?php if (isset($row['Default'])) { echo $row['Default']; } ?>&nbsp;</td>
<!--<td width="50" bgcolor="<?php echo $bgcolor; ?>" nowrap="nowrap"><?php echo $row['Extra']; ?>&nbsp;</td>--> <!--<td><?php echo $row['Extra']; ?>&nbsp;</td>-->
<?php <?php
echo "\n";
if ($have_rel) { if ($have_rel) {
echo ' <td class="print">'; echo ' <td>';
if (isset($res_rel[$field_name])) { if (isset($res_rel[$field_name])) {
echo htmlspecialchars($res_rel[$field_name]['foreign_table'] . ' -> ' . $res_rel[$field_name]['foreign_field'] ); echo htmlspecialchars($res_rel[$field_name]['foreign_table'] . ' -> ' . $res_rel[$field_name]['foreign_field'] );
} }
echo '&nbsp;</td>' . "\n"; echo '&nbsp;</td>' . "\n";
} }
if ($cfgRelation['commwork'] || PMA_MYSQL_INT_VERSION >= 40100) { if ($cfgRelation['commwork'] || PMA_MYSQL_INT_VERSION >= 40100) {
echo ' <td class="print">'; echo ' <td>';
$comments = PMA_getComments($db, $table); $comments = PMA_getComments($db, $table);
if (isset($comments[$field_name])) { if (isset($comments[$field_name])) {
echo htmlspecialchars($comments[$field_name]); echo htmlspecialchars($comments[$field_name]);
@@ -241,7 +237,7 @@ foreach ($the_tables AS $key => $table) {
if ($cfgRelation['mimework']) { if ($cfgRelation['mimework']) {
$mime_map = PMA_getMIME($db, $table, true); $mime_map = PMA_getMIME($db, $table, true);
echo ' <td class="print">'; echo ' <td>';
if (isset($mime_map[$field_name])) { if (isset($mime_map[$field_name])) {
echo htmlspecialchars(str_replace('_', '/', $mime_map[$field_name]['mimetype'])); echo htmlspecialchars(str_replace('_', '/', $mime_map[$field_name]['mimetype']));
} }
@@ -252,12 +248,10 @@ foreach ($the_tables AS $key => $table) {
<?php <?php
} // end while } // end while
PMA_DBI_free_result($result); PMA_DBI_free_result($result);
echo "\n";
?> ?>
</tbody>
</table> </table>
<?php <?php
if ( ! $tbl_is_view if ( ! $tbl_is_view
@@ -276,8 +270,8 @@ foreach ($the_tables AS $key => $table) {
<br /><br /> <br /><br />
<!-- Indexes --> <!-- Indexes -->
&nbsp;<big><?php echo $strIndexes . ':'; ?></big> <big><?php echo $strIndexes . ':'; ?></big>
<table bordercolorlight="black" border="border" style="border-collapse: collapse; background-color: white"> <table>
<tr> <tr>
<th><?php echo $strKeyname; ?></th> <th><?php echo $strKeyname; ?></th>
<th><?php echo $strType; ?></th> <th><?php echo $strType; ?></th>
@@ -301,18 +295,18 @@ foreach ($the_tables AS $key => $table) {
* staybyte - 9 June 2001 * staybyte - 9 June 2001
*/ */
if ($cfg['ShowStats']) { if ($cfg['ShowStats']) {
$nonisam = FALSE; $nonisam = false;
if (isset($showtable['Type']) && !preg_match('@ISAM|HEAP@i', $showtable['Type'])) { if (isset($showtable['Type']) && !preg_match('@ISAM|HEAP@i', $showtable['Type'])) {
$nonisam = TRUE; $nonisam = true;
} }
if ($nonisam == FALSE) { if ($nonisam == false) {
// Gets some sizes // Gets some sizes
$mergetable = FALSE; $mergetable = false;
if (isset($showtable['Type']) && $showtable['Type'] == 'MRG_MyISAM') { if (isset($showtable['Type']) && $showtable['Type'] == 'MRG_MyISAM') {
$mergetable = TRUE; $mergetable = true;
} }
list($data_size, $data_unit) = PMA_formatByteDown($showtable['Data_length']); list($data_size, $data_unit) = PMA_formatByteDown($showtable['Data_length']);
if ($mergetable == FALSE) { if ($mergetable == false) {
list($index_size, $index_unit) = PMA_formatByteDown($showtable['Index_length']); list($index_size, $index_unit) = PMA_formatByteDown($showtable['Index_length']);
} }
if (isset($showtable['Data_free']) && $showtable['Data_free'] > 0) { if (isset($showtable['Data_free']) && $showtable['Data_free'] > 0) {
@@ -336,26 +330,26 @@ foreach ($the_tables AS $key => $table) {
<tr> <tr>
<!-- Space usage --> <!-- Space usage -->
<td class="print" valign="top"> <td valign="top">
&nbsp;<big><?php echo $strSpaceUsage . ':'; ?></big> <big><?php echo $strSpaceUsage . ':'; ?></big>
<table width="100%" bordercolorlight="black" border="border" style="border-collapse: collapse; background-color: white"> <table width="100%">
<tr> <tr>
<th><?php echo $strType; ?></th> <th><?php echo $strType; ?></th>
<th colspan="2" align="center"><?php echo $strUsage; ?></th> <th colspan="2" align="center"><?php echo $strUsage; ?></th>
</tr> </tr>
<tr> <tr>
<td class="print" style="padding-right: 10px"><?php echo $strData; ?></td> <td style="padding-right: 10px"><?php echo $strData; ?></td>
<td align="right" class="print" nowrap="nowrap"><?php echo $data_size; ?></td> <td align="right"><?php echo $data_size; ?></td>
<td class="print"><?php echo $data_unit; ?></td> <td><?php echo $data_unit; ?></td>
</tr> </tr>
<?php <?php
if (isset($index_size)) { if (isset($index_size)) {
echo "\n"; echo "\n";
?> ?>
<tr> <tr>
<td class="print" style="padding-right: 10px"><?php echo $strIndex; ?></td> <td style="padding-right: 10px"><?php echo $strIndex; ?></td>
<td align="right" class="print" nowrap="nowrap"><?php echo $index_size; ?></td> <td align="right"><?php echo $index_size; ?></td>
<td class="print"><?php echo $index_unit; ?></td> <td><?php echo $index_unit; ?></td>
</tr> </tr>
<?php <?php
} }
@@ -363,24 +357,24 @@ foreach ($the_tables AS $key => $table) {
echo "\n"; echo "\n";
?> ?>
<tr style="color: #bb0000"> <tr style="color: #bb0000">
<td class="print" style="padding-right: 10px"><?php echo $strOverhead; ?></td> <td style="padding-right: 10px"><?php echo $strOverhead; ?></td>
<td align="right" class="print" nowrap="nowrap"><?php echo $free_size; ?></td> <td align="right"><?php echo $free_size; ?></td>
<td class="print"><?php echo $free_unit; ?></td> <td><?php echo $free_unit; ?></td>
</tr> </tr>
<tr> <tr>
<td class="print" style="padding-right: 10px"><?php echo $strEffective; ?></td> <td style="padding-right: 10px"><?php echo $strEffective; ?></td>
<td align="right" class="print" nowrap="nowrap"><?php echo $effect_size; ?></td> <td align="right"><?php echo $effect_size; ?></td>
<td class="print"><?php echo $effect_unit; ?></td> <td><?php echo $effect_unit; ?></td>
</tr> </tr>
<?php <?php
} }
if (isset($tot_size) && $mergetable == FALSE) { if (isset($tot_size) && $mergetable == false) {
echo "\n"; echo "\n";
?> ?>
<tr> <tr>
<td class="print" style="padding-right: 10px"><?php echo $strTotalUC; ?></td> <td style="padding-right: 10px"><?php echo $strTotalUC; ?></td>
<td align="right" class="print" nowrap="nowrap"><?php echo $tot_size; ?></td> <td align="right"><?php echo $tot_size; ?></td>
<td class="print"><?php echo $tot_unit; ?></td> <td><?php echo $tot_unit; ?></td>
</tr> </tr>
<?php <?php
} }
@@ -389,27 +383,23 @@ foreach ($the_tables AS $key => $table) {
</table> </table>
</td> </td>
<td width="20" class="print">&nbsp;</td> <td width="20">&nbsp;</td>
<!-- Rows Statistic --> <!-- Rows Statistic -->
<td valign="top"> <td valign="top">
&nbsp;<big><?php echo $strRowsStatistic . ':'; ?></big> <big><?php echo $strRowsStatistic . ':'; ?></big>
<table width=100% bordercolorlight="black" border="border" style="border-collapse: collapse; background-color: white"> <table width="100%">
<tr> <tr>
<th><?php echo $strStatement; ?></th> <th><?php echo $strStatement; ?></th>
<th align="center"><?php echo $strValue; ?></th> <th align="center"><?php echo $strValue; ?></th>
</tr> </tr>
<?php <?php
$i = 0;
if (isset($showtable['Row_format'])) { if (isset($showtable['Row_format'])) {
$bgcolor = ((++$i%2) ? $cfg['BgcolorTwo'] : $cfg['BgcolorOne']);
echo "\n";
?> ?>
<tr> <tr>
<td class="print"><?php echo ucfirst($strFormat); ?></td> <td><?php echo ucfirst($strFormat); ?></td>
<td align="<?php echo $cell_align_left; ?>" class="print" nowrap="nowrap"> <td align="<?php echo $cell_align_left; ?>">
<?php <?php
echo ' ';
if ($showtable['Row_format'] == 'Fixed') { if ($showtable['Row_format'] == 'Fixed') {
echo $strFixed; echo $strFixed;
} elseif ($showtable['Row_format'] == 'Dynamic') { } elseif ($showtable['Row_format'] == 'Dynamic') {
@@ -417,131 +407,105 @@ foreach ($the_tables AS $key => $table) {
} else { } else {
echo $showtable['Row_format']; echo $showtable['Row_format'];
} }
echo "\n";
?> ?>
</td> </td>
</tr> </tr>
<?php <?php
} }
if (isset($showtable['Rows'])) { if (isset($showtable['Rows'])) {
$bgcolor = ((++$i%2) ? $cfg['BgcolorTwo'] : $cfg['BgcolorOne']);
echo "\n";
?> ?>
<tr> <tr>
<td class="print"><?php echo ucfirst($strRows); ?></td> <td><?php echo ucfirst($strRows); ?></td>
<td align="right" class="print" nowrap="nowrap"> <td align="right">
<?php echo number_format($showtable['Rows'], 0, $number_decimal_separator, $number_thousands_separator) . "\n"; ?> <?php echo number_format($showtable['Rows'], 0, $number_decimal_separator, $number_thousands_separator) . "\n"; ?>
</td> </td>
</tr> </tr>
<?php <?php
} }
if (isset($showtable['Avg_row_length']) && $showtable['Avg_row_length'] > 0) { if (isset($showtable['Avg_row_length']) && $showtable['Avg_row_length'] > 0) {
$bgcolor = ((++$i%2) ? $cfg['BgcolorTwo'] : $cfg['BgcolorOne']);
echo "\n";
?> ?>
<tr> <tr>
<td class="print"><?php echo ucfirst($strRowLength); ?>&nbsp;&oslash;</td> <td><?php echo ucfirst($strRowLength); ?>&nbsp;&oslash;</td>
<td class="print" nowrap="nowrap"> <td>
<?php echo number_format($showtable['Avg_row_length'], 0, $number_decimal_separator, $number_thousands_separator) . "\n"; ?> <?php echo number_format($showtable['Avg_row_length'], 0, $number_decimal_separator, $number_thousands_separator) . "\n"; ?>
</td> </td>
</tr> </tr>
<?php <?php
} }
if (isset($showtable['Data_length']) && $showtable['Rows'] > 0 && $mergetable == FALSE) { if (isset($showtable['Data_length']) && $showtable['Rows'] > 0 && $mergetable == false) {
$bgcolor = ((++$i%2) ? $cfg['BgcolorTwo'] : $cfg['BgcolorOne']);
echo "\n";
?> ?>
<tr> <tr>
<td class="print"><?php echo ucfirst($strRowSize); ?>&nbsp;&oslash;</td> <td><?php echo ucfirst($strRowSize); ?>&nbsp;&oslash;</td>
<td align="right" class="print" nowrap="nowrap"> <td align="right">
<?php echo $avg_size . ' ' . $avg_unit . "\n"; ?> <?php echo $avg_size . ' ' . $avg_unit . "\n"; ?>
</td> </td>
</tr> </tr>
<?php <?php
} }
if (isset($showtable['Auto_increment'])) { if (isset($showtable['Auto_increment'])) {
$bgcolor = ((++$i%2) ? $cfg['BgcolorTwo'] : $cfg['BgcolorOne']);
echo "\n";
?> ?>
<tr> <tr>
<td class="print"><?php echo ucfirst($strNext); ?>&nbsp;Autoindex</td> <td><?php echo ucfirst($strNext); ?>&nbsp;Autoindex</td>
<td align="right" class="print" nowrap="nowrap"> <td align="right">
<?php echo number_format($showtable['Auto_increment'], 0, $number_decimal_separator, $number_thousands_separator) . "\n"; ?> <?php echo number_format($showtable['Auto_increment'], 0, $number_decimal_separator, $number_thousands_separator) . "\n"; ?>
</td> </td>
</tr> </tr>
<?php <?php
} }
echo "\n";
if (isset($showtable['Create_time'])) { if (isset($showtable['Create_time'])) {
$bgcolor = ((++$i%2) ? $cfg['BgcolorTwo'] : $cfg['BgcolorOne']);
echo "\n";
?> ?>
<tr> <tr>
<td class="print"><?php echo $strStatCreateTime; ?></td> <td><?php echo $strStatCreateTime; ?></td>
<td align="right" class="print" nowrap="nowrap"> <td align="right">
<?php echo PMA_localisedDate(strtotime($showtable['Create_time'])) . "\n"; ?> <?php echo PMA_localisedDate(strtotime($showtable['Create_time'])) . "\n"; ?>
</td> </td>
</tr> </tr>
<?php <?php
} }
echo "\n";
if (isset($showtable['Update_time'])) { if (isset($showtable['Update_time'])) {
$bgcolor = ((++$i%2) ? $cfg['BgcolorTwo'] : $cfg['BgcolorOne']);
echo "\n";
?> ?>
<tr> <tr>
<td class="print"><?php echo $strStatUpdateTime; ?></td> <td><?php echo $strStatUpdateTime; ?></td>
<td align="right" class="print" nowrap="nowrap"> <td align="right">
<?php echo PMA_localisedDate(strtotime($showtable['Update_time'])) . "\n"; ?> <?php echo PMA_localisedDate(strtotime($showtable['Update_time'])) . "\n"; ?>
</td> </td>
</tr> </tr>
<?php <?php
} }
echo "\n";
if (isset($showtable['Check_time'])) { if (isset($showtable['Check_time'])) {
$bgcolor = ((++$i%2) ? $cfg['BgcolorTwo'] : $cfg['BgcolorOne']);
echo "\n";
?> ?>
<tr> <tr>
<td class="print"><?php echo $strStatCheckTime; ?></td> <td><?php echo $strStatCheckTime; ?></td>
<td align="right" class="print" nowrap="nowrap"> <td align="right">
<?php echo PMA_localisedDate(strtotime($showtable['Check_time'])) . "\n"; ?> <?php echo PMA_localisedDate(strtotime($showtable['Check_time'])) . "\n"; ?>
</td> </td>
</tr> </tr>
<?php <?php
} }
echo "\n";
?> ?>
</table> </table>
</td> </td>
</tr> </tr>
</table> </table>
<?php <?php
} // end if ($nonisam == FALSE) } // end if ($nonisam == false)
} // end if ($cfg['ShowStats']) } // end if ($cfg['ShowStats'])
} }
echo "\n";
if ($multi_tables) { if ($multi_tables) {
unset($ret_keys); unset($ret_keys, $num_rows, $show_comment);
unset($num_rows);
unset($show_comment);
echo '<hr />' . "\n"; echo '<hr />' . "\n";
} // end if } // end if
echo '</div>' . "\n"; echo '</div>' . "\n";
} // end while } // end while
/** /**
* Displays the footer * Displays the footer
*/ */
echo "\n";
?> ?>
<script type="text/javascript" language="javascript"> <script type="text/javascript" language="javascript">
//<![CDATA[ //<![CDATA[
function printPage() function printPage()
@@ -553,8 +517,11 @@ function printPage()
} }
//]]> //]]>
</script> </script>
<?php
echo '<br /><br />&nbsp;<input type="button" class="print_ignore" style="width: 100px; height: 25px" id="print" value="' . $strPrint . '" onclick="printPage()" />' . "\n";
require_once('./libraries/footer.inc.php'); <p class="print_ignore">
<input type="button" id="print" value="<?php echo $strPrint; ?>"
onclick="printPage()" /></p>
<?php
require_once './libraries/footer.inc.php';
?> ?>