' . $strNoTablesFound . '
' . "\n";
if (empty($db_is_information_schema)) {
require './libraries/display_create_table.lib.php';
} // end if (Create Table dialog)
/**
* Displays the footer
*/
require_once './libraries/footer.inc.php';
exit;
}
// else
// 2. Shows table informations - staybyte - 11 June 2001
require_once './libraries/bookmark.lib.php';
require_once './libraries/mysql_charsets.lib.php';
$db_collation = PMA_getDbCollation($db);
// Display function
/**
* void PMA_TableHeader([bool $db_is_information_schema = false])
* display table header (... )
*
* @uses PMA_showHint()
* @uses $GLOBALS['cfg']['PropertiesNumColumns']
* @uses $GLOBALS['is_show_stats']
* @uses $GLOBALS['strTable']
* @uses $GLOBALS['strAction']
* @uses $GLOBALS['strRecords']
* @uses $GLOBALS['strApproximateCount']
* @uses $GLOBALS['strType']
* @uses $GLOBALS['strCollation']
* @uses $GLOBALS['strSize']
* @uses $GLOBALS['strOverhead']
* @uses $GLOBALS['structure_tbl_col_cnt']
* @uses PMA_SortableTableHeader()
* @param boolean $db_is_information_schema
*/
function PMA_TableHeader($db_is_information_schema = false)
{
$cnt = 0; // Let's count the columns...
if ($db_is_information_schema) {
$action_colspan = 3;
} else {
$action_colspan = 6;
}
echo '' . "\n"
.'' . "\n"
.' ' . "\n"
.' ' . PMA_SortableTableHeader($GLOBALS['strTable'], 'table') . ' ' . "\n"
.' ' . "\n"
.' ' . $GLOBALS['strAction'] . "\n"
.' '
.' ' . PMA_SortableTableHeader($GLOBALS['strRecords'], 'records')
.PMA_showHint(PMA_sanitize($GLOBALS['strApproximateCount'])) . "\n"
.' ' . "\n";
if (!($GLOBALS['cfg']['PropertiesNumColumns'] > 1)) {
echo ' ' . PMA_SortableTableHeader($GLOBALS['strType'], 'type') . ' ' . "\n";
$cnt++;
echo ' ' . PMA_SortableTableHeader($GLOBALS['strCollation'], 'collation') . ' ' . "\n";
$cnt++;
}
if ($GLOBALS['is_show_stats']) {
echo ' ' . PMA_SortableTableHeader($GLOBALS['strSize'], 'size') . ' ' . "\n"
. ' ' . PMA_SortableTableHeader($GLOBALS['strOverhead'], 'overhead') . ' ' . "\n";
$cnt += 2;
}
echo ' ' . "\n";
echo ' ' . "\n";
echo '' . "\n";
$GLOBALS['structure_tbl_col_cnt'] = $cnt + $action_colspan + 3;
} // end function PMA_TableHeader()
/**
* Creates a clickable column header for table information
*
* @param string title to use for the link
* @param string corresponds to sortable data name mapped in libraries/db_info.inc.php
* @returns string link to be displayed in the table header
*/
function PMA_SortableTableHeader($title, $sort)
{
// Set some defaults
$requested_sort = 'table';
$requested_sort_order = 'ASC';
$future_sort_order = 'ASC';
// If the user requested a sort
if (isset($_REQUEST['sort'])) {
$requested_sort = $_REQUEST['sort'];
if (isset($_REQUEST['sort_order'])) {
$requested_sort_order = $_REQUEST['sort_order'];
}
}
$order_img = '';
$order_link_params = array();
$order_link_params['title'] = $GLOBALS['strSort'];
// If this column was requested to be sorted.
if ($requested_sort == $sort) {
if ($requested_sort_order == 'ASC') {
$future_sort_order = 'DESC';
// current sort order is ASC
$order_img = ' ';
// but on mouse over, show the reverse order (DESC)
$order_link_params['onmouseover'] = 'if(document.getElementById(\'sort_arrow\')){ document.getElementById(\'sort_arrow\').src=\'' . $GLOBALS['pmaThemeImage'] . 's_desc.png\'; }';
// on mouse out, show current sort order (ASC)
$order_link_params['onmouseout'] = 'if(document.getElementById(\'sort_arrow\')){ document.getElementById(\'sort_arrow\').src=\'' . $GLOBALS['pmaThemeImage'] . 's_asc.png\'; }';
} else {
// current sort order is DESC
$order_img = ' ';
// but on mouse over, show the reverse order (ASC)
$order_link_params['onmouseover'] = 'if(document.getElementById(\'sort_arrow\')){ document.getElementById(\'sort_arrow\').src=\'' . $GLOBALS['pmaThemeImage'] . 's_asc.png\'; }';
// on mouse out, show current sort order (DESC)
$order_link_params['onmouseout'] = 'if(document.getElementById(\'sort_arrow\')){ document.getElementById(\'sort_arrow\').src=\'' . $GLOBALS['pmaThemeImage'] . 's_desc.png\'; }';
}
}
$_url_params = array(
'db' => $_REQUEST['db'],
);
$url = 'db_structure.php'.PMA_generate_common_url($_url_params);
// We set the position back to 0 every time they sort.
$url .= "&pos=0&sort=$sort&sort_order=$future_sort_order";
return PMA_linkOrButton($url, $title . $order_img, $order_link_params);
} // end function PMA_SortableTableHeader()
$titles = array();
if (true == $cfg['PropertiesIconic']) {
$titles['Browse'] = ' ';
$titles['NoBrowse'] = ' ';
$titles['Search'] = ' ';
$titles['NoSearch'] = ' ';
$titles['Insert'] = ' ';
$titles['NoInsert'] = ' ';
$titles['Structure'] = ' ';
$titles['Drop'] = ' ';
$titles['NoDrop'] = ' ';
$titles['Empty'] = ' ';
$titles['NoEmpty'] = ' ';
if ('both' === $cfg['PropertiesIconic']) {
$titles['Browse'] .= $strBrowse;
$titles['Search'] .= $strSearch;
$titles['NoBrowse'] .= $strBrowse;
$titles['NoSearch'] .= $strSearch;
$titles['Insert'] .= $strInsert;
$titles['NoInsert'] .= $strInsert;
$titles['Structure'] .= $strStructure;
$titles['Drop'] .= $strDrop;
$titles['NoDrop'] .= $strDrop;
$titles['Empty'] .= $strEmpty;
$titles['NoEmpty'] .= $strEmpty;
}
} else {
$titles['Browse'] = $strBrowse;
$titles['Search'] = $strSearch;
$titles['NoBrowse'] = $strBrowse;
$titles['NoSearch'] = $strSearch;
$titles['Insert'] = $strInsert;
$titles['NoInsert'] = $strInsert;
$titles['Structure'] = $strStructure;
$titles['Drop'] = $strDrop;
$titles['NoDrop'] = $strDrop;
$titles['Empty'] = $strEmpty;
$titles['NoEmpty'] = $strEmpty;
}
/**
* Displays the tables list
*/
$_url_params = array(
'pos' => $pos,
'db' => $db);
// Add the sort options if they exists
if (isset($_REQUEST['sort'])) {
$_url_params['sort'] = $_REQUEST['sort'];
}
if (isset($_REQUEST['sort_order'])) {
$_url_params['sort_order'] = $_REQUEST['sort_order'];
}
PMA_listNavigator($total_num_tables, $pos, $_url_params, 'db_structure.php', 'frame_content', $GLOBALS['cfg']['MaxTableList']);
?>
/>
= $GLOBALS['cfg']['MaxExactCountViews']){
$row_count_pre = '~';
$sum_row_count_pre = '~';
$show_superscript = PMA_showHint(PMA_sanitize(sprintf($strViewHasAtLeast, '[a@./Documentation.html#cfg_MaxExactCountViews@_blank]', '[/a]')));
}
} elseif($each_table['ENGINE'] == 'InnoDB' && (! $each_table['COUNTED'])) {
// InnoDB table: we did not get an accurate row count
$row_count_pre = '~';
$sum_row_count_pre = '~';
$show_superscript = '';
} else {
$row_count_pre = '';
$show_superscript = '';
}
?>
1)) { ?>
-
---
-
-
1)) {
$default_engine = PMA_DBI_get_default_engine();
echo ' ' . "\n"
. ' ' .$default_engine . ' ' . "\n";
// we got a case where $db_collation was empty
echo ' ' . "\n";
if (! empty($db_collation)) {
echo ' ' . $db_collation
. ' ';
}
echo ' ';
}
if ($is_show_stats) {
?>
50100) {
require './libraries/db_events.inc.php';
}
/**
* Work on the database
* redesigned 2004-05-08 by mkkeck
*/
/* DATABASE WORK */
/* Printable view of a table */
echo '';
echo '';
if ($cfg['PropertiesIconic']) {
echo ' ';
}
echo $strPrintView . ' ';
echo '';
if ($cfg['PropertiesIconic']) {
echo ' ';
}
echo $strDataDict . ' ';
echo '
';
if (empty($db_is_information_schema)) {
require './libraries/display_create_table.lib.php';
} // end if (Create Table dialog)
/**
* Displays the footer
*/
require_once './libraries/footer.inc.php';
?>