bug #3072502 Text not shown for icons after creating table

This commit is contained in:
Marc Delisle
2010-09-26 08:39:28 -04:00
parent ddc99a3dee
commit eef35043dd
3 changed files with 61 additions and 53 deletions

View File

@@ -70,47 +70,7 @@ $db_collation = PMA_getDbCollation($db);
// in a separate file to avoid redeclaration of functions in some code paths // in a separate file to avoid redeclaration of functions in some code paths
require_once './libraries/db_structure.lib.php'; require_once './libraries/db_structure.lib.php';
require_once './libraries/build_action_titles.inc.php';
$titles = array();
if (true == $cfg['PropertiesIconic']) {
$titles['Browse'] = '<img class="icon" width="16" height="16" src="' .$pmaThemeImage . 'b_browse.png" alt="' . __('Browse') . '" title="' . __('Browse') . '" />';
$titles['NoBrowse'] = '<img class="icon" width="16" height="16" src="' .$pmaThemeImage . 'bd_browse.png" alt="' . __('Browse') . '" title="' . __('Browse') . '" />';
$titles['Search'] = '<img class="icon" width="16" height="16" src="' .$pmaThemeImage . 'b_select.png" alt="' . __('Search') . '" title="' . __('Search') . '" />';
$titles['NoSearch'] = '<img class="icon" width="16" height="16" src="' .$pmaThemeImage . 'bd_select.png" alt="' . __('Search') . '" title="' . __('Search') . '" />';
$titles['Insert'] = '<img class="icon" width="16" height="16" src="' .$pmaThemeImage . 'b_insrow.png" alt="' . __('Insert') . '" title="' . __('Insert') . '" />';
$titles['NoInsert'] = '<img class="icon" width="16" height="16" src="' .$pmaThemeImage . 'bd_insrow.png" alt="' . __('Insert') . '" title="' . __('Insert') . '" />';
$titles['Structure'] = '<img class="icon" width="16" height="16" src="' .$pmaThemeImage . 'b_props.png" alt="' . __('Structure') . '" title="' . __('Structure') . '" />';
$titles['Drop'] = '<img class="icon" width="16" height="16" src="' .$pmaThemeImage . 'b_drop.png" alt="' . __('Drop') . '" title="' . __('Drop') . '" />';
$titles['NoDrop'] = '<img class="icon" width="16" height="16" src="' .$pmaThemeImage . 'bd_drop.png" alt="' . __('Drop') . '" title="' . __('Drop') . '" />';
$titles['Empty'] = '<img class="icon" width="16" height="16" src="' .$pmaThemeImage . 'b_empty.png" alt="' . __('Empty') . '" title="' . __('Empty') . '" />';
$titles['NoEmpty'] = '<img class="icon" width="16" height="16" src="' .$pmaThemeImage . 'bd_empty.png" alt="' . __('Empty') . '" title="' . __('Empty') . '" />';
if ('both' === $cfg['PropertiesIconic']) {
$titles['Browse'] .= __('Browse');
$titles['Search'] .= __('Search');
$titles['NoBrowse'] .= __('Browse');
$titles['NoSearch'] .= __('Search');
$titles['Insert'] .= __('Insert');
$titles['NoInsert'] .= __('Insert');
$titles['Structure'] .= __('Structure');
$titles['Drop'] .= __('Drop');
$titles['NoDrop'] .= __('Drop');
$titles['Empty'] .= __('Empty');
$titles['NoEmpty'] .= __('Empty');
}
} else {
$titles['Browse'] = __('Browse');
$titles['Search'] = __('Search');
$titles['NoBrowse'] = __('Browse');
$titles['NoSearch'] = __('Search');
$titles['Insert'] = __('Insert');
$titles['NoInsert'] = __('Insert');
$titles['Structure'] = __('Structure');
$titles['Drop'] = __('Drop');
$titles['NoDrop'] = __('Drop');
$titles['Empty'] = __('Empty');
$titles['NoEmpty'] = __('Empty');
}
/** /**
* Displays the tables list * Displays the tables list

View File

@@ -0,0 +1,51 @@
<?php
/* vim: set expandtab sw=4 ts=4 sts=4: */
/**
*
* @package phpMyAdmin
*/
if (! defined('PHPMYADMIN')) {
exit;
}
$titles = array();
if (true == $cfg['PropertiesIconic']) {
$titles['Browse'] = '<img class="icon" width="16" height="16" src="' .$pmaThemeImage . 'b_browse.png" alt="' . __('Browse') . '" title="' . __('Browse') . '" />';
$titles['NoBrowse'] = '<img class="icon" width="16" height="16" src="' .$pmaThemeImage . 'bd_browse.png" alt="' . __('Browse') . '" title="' . __('Browse') . '" />';
$titles['Search'] = '<img class="icon" width="16" height="16" src="' .$pmaThemeImage . 'b_select.png" alt="' . __('Search') . '" title="' . __('Search') . '" />';
$titles['NoSearch'] = '<img class="icon" width="16" height="16" src="' .$pmaThemeImage . 'bd_select.png" alt="' . __('Search') . '" title="' . __('Search') . '" />';
$titles['Insert'] = '<img class="icon" width="16" height="16" src="' .$pmaThemeImage . 'b_insrow.png" alt="' . __('Insert') . '" title="' . __('Insert') . '" />';
$titles['NoInsert'] = '<img class="icon" width="16" height="16" src="' .$pmaThemeImage . 'bd_insrow.png" alt="' . __('Insert') . '" title="' . __('Insert') . '" />';
$titles['Structure'] = '<img class="icon" width="16" height="16" src="' .$pmaThemeImage . 'b_props.png" alt="' . __('Structure') . '" title="' . __('Structure') . '" />';
$titles['Drop'] = '<img class="icon" width="16" height="16" src="' .$pmaThemeImage . 'b_drop.png" alt="' . __('Drop') . '" title="' . __('Drop') . '" />';
$titles['NoDrop'] = '<img class="icon" width="16" height="16" src="' .$pmaThemeImage . 'bd_drop.png" alt="' . __('Drop') . '" title="' . __('Drop') . '" />';
$titles['Empty'] = '<img class="icon" width="16" height="16" src="' .$pmaThemeImage . 'b_empty.png" alt="' . __('Empty') . '" title="' . __('Empty') . '" />';
$titles['NoEmpty'] = '<img class="icon" width="16" height="16" src="' .$pmaThemeImage . 'bd_empty.png" alt="' . __('Empty') . '" title="' . __('Empty') . '" />';
if ('both' === $cfg['PropertiesIconic']) {
$titles['Browse'] .= __('Browse');
$titles['Search'] .= __('Search');
$titles['NoBrowse'] .= __('Browse');
$titles['NoSearch'] .= __('Search');
$titles['Insert'] .= __('Insert');
$titles['NoInsert'] .= __('Insert');
$titles['Structure'] .= __('Structure');
$titles['Drop'] .= __('Drop');
$titles['NoDrop'] .= __('Drop');
$titles['Empty'] .= __('Empty');
$titles['NoEmpty'] .= __('Empty');
}
} else {
$titles['Browse'] = __('Browse');
$titles['Search'] = __('Search');
$titles['NoBrowse'] = __('Browse');
$titles['NoSearch'] = __('Search');
$titles['Insert'] = __('Insert');
$titles['NoInsert'] = __('Insert');
$titles['Structure'] = __('Structure');
$titles['Drop'] = __('Drop');
$titles['NoDrop'] = __('Drop');
$titles['Empty'] = __('Empty');
$titles['NoEmpty'] = __('Empty');
}
?>

View File

@@ -38,6 +38,7 @@ require_once './libraries/common.inc.php';
$action = 'tbl_create.php'; $action = 'tbl_create.php';
require_once './libraries/header.inc.php'; require_once './libraries/header.inc.php';
require_once './libraries/build_action_titles.inc.php';
// Check parameters // Check parameters
PMA_checkParameters(array('db')); PMA_checkParameters(array('db'));
@@ -299,25 +300,21 @@ if (isset($_REQUEST['do_save_data'])) {
} }
$new_table_string .= '</th>' . "\n"; $new_table_string .= '</th>' . "\n";
$new_table_string .= '<td> <img class="icon" width="16" height="16" src="' .$pmaThemeImage . 'bd_browse.png" alt="' . __('Browse') . '" title="' . __('Browse') . '" /> </td>' . "\n"; $new_table_string .= '<td>' . $titles['NoBrowse'] . '</td>' . "\n";
$new_table_string .= '<td> <a href="tbl_structure.php' . PMA_generate_common_url($tbl_url_params) . '"> '; $new_table_string .= '<td><a href="tbl_structure.php' . PMA_generate_common_url($tbl_url_params) . '">' . $titles['Structure'] . '</a></td>' . "\n";
$new_table_string .= '<img class="icon" width="16" height="16" src="' .$pmaThemeImage . 'b_props.png" alt="' . __('Structure') . '" title="' . __('Structure') . '" />';
$new_table_string .= '</a> </td>' . "\n";
$new_table_string .= '<td> <img class="icon" width="16" height="16" src="' .$pmaThemeImage . 'bd_select.png" alt="' . __('Search') . '" title="' . __('Search') . '" /> </td>' . "\n"; $new_table_string .= '<td>' . $titles['NoSearch'] . '</td>' . "\n";
$new_table_string .= '<td> <a href="tbl_change.php' . PMA_generate_common_url($tbl_url_params) . '"> '; $new_table_string .= '<td><a href="tbl_change.php' . PMA_generate_common_url($tbl_url_params) . '">' . $titles['Insert'] . '</a></td>' . "\n";
$new_table_string .= '<img class="icon" width="16" height="16" src="' .$pmaThemeImage . 'b_insrow.png" alt="' . __('Insert') . '" title="' . __('Insert') . '" />';
$new_table_string .= '</a> </td>' . "\n";
$new_table_string .= '<td> <img class="icon" width="16" height="16" src="' .$pmaThemeImage . 'bd_empty.png" alt="' . __('Empty') . '" title="' . __('Empty') . '" /> </td>' . "\n"; $new_table_string .= '<td>' . $titles['NoEmpty'] . '</td>' . "\n";
$new_table_string .= '<td> <a class="drop_table_anchor" href="sql.php' . PMA_generate_common_url($tbl_url_params) . '&amp;sql_query='; $new_table_string .= '<td><a class="drop_table_anchor" href="sql.php' . PMA_generate_common_url($tbl_url_params) . '&amp;sql_query=';
$new_table_string .= urlencode('DROP TABLE ' . PMA_backquote($table)); $new_table_string .= urlencode('DROP TABLE ' . PMA_backquote($table));
$new_table_string .= '">'; $new_table_string .= '">';
$new_table_string .= '<img class="icon" width="16" height="16" src="' .$pmaThemeImage . 'b_drop.png" alt="' . __('Drop') . '" title="' . __('Drop') . '" />'; $new_table_string .= $titles['Drop'];
$new_table_string .= '</a> </td>' . "\n"; $new_table_string .= '</a></td>' . "\n";
$new_table_string .= '<td class="value">' . $tbl_stats['Rows'] . '</td>' . "\n"; $new_table_string .= '<td class="value">' . $tbl_stats['Rows'] . '</td>' . "\n";