bug #4147 Accessibility: Images without Alt nor title attribute

This commit is contained in:
Marc Delisle 2013-10-30 08:00:13 -04:00
parent 2a5f6a2ddc
commit 266ee805b0
15 changed files with 41 additions and 19 deletions

View File

@ -11,6 +11,7 @@ phpMyAdmin - ChangeLog
- bug #4120 SSL redirects to port 80
- bug #4144 DROP DATABASE displays wrong database name
- bug #4059 Running delete query asks for confirmation but says it was already executed
- bug #4147 Accessibility: Images without Alt nor title attribute
4.0.8.0 (2013-10-06)
- bug #3988 Rename view is not working

View File

@ -827,7 +827,7 @@ class PMA_NavigationTree
if (strpos($class, 'last') === false) {
$retval .= "<b></b>";
}
$icon = PMA_Util::getImage('b_plus.png');
$icon = PMA_Util::getImage('b_plus.png', __('Expand/Collapse'));
$match = 1;
foreach ($this->_aPath as $path) {
$match = 1;

View File

@ -29,7 +29,7 @@ class Node_Column extends Node
public function __construct($name, $type = Node::OBJECT, $is_group = false)
{
parent::__construct($name, $type, $is_group);
$this->icon = PMA_Util::getImage('pause.png', '');
$this->icon = PMA_Util::getImage('pause.png', __('Column'));
$this->links = array(
'text' => 'tbl_structure.php?server=' . $GLOBALS['server']
. '&amp;db=%3$s&amp;table=%2$s&amp;field=%1$s'

View File

@ -24,7 +24,7 @@ class Node_Column_Container extends Node
public function __construct()
{
parent::__construct(__('Columns'), Node::CONTAINER);
$this->icon = PMA_Util::getImage('pause.png', '');
$this->icon = PMA_Util::getImage('pause.png', __('Columns'));
$this->links = array(
'text' => 'tbl_structure.php?server=' . $GLOBALS['server']
. '&amp;db=%2$s&amp;table=%1$s'
@ -37,7 +37,7 @@ class Node_Column_Container extends Node
$new = PMA_NodeFactory::getInstance('Node', _pgettext('Create new column', 'New'));
$new->isNew = true;
$new->icon = PMA_Util::getImage('b_column_add.png', '');
$new->icon = PMA_Util::getImage('b_column_add.png', __('New'));
$new->links = array(
'text' => 'tbl_addfield.php?server=' . $GLOBALS['server']
. '&amp;db=%3$s&amp;table=%2$s'

View File

@ -27,7 +27,10 @@ class Node_Database extends Node
public function __construct($name, $type = Node::OBJECT, $is_group = false)
{
parent::__construct($name, $type, $is_group);
$this->icon = PMA_Util::getImage('s_db.png');
$this->icon = PMA_Util::getImage(
's_db.png',
__('Database operations')
);
$this->links = array(
'text' => $GLOBALS['cfg']['DefaultTabDatabase']
. '?server=' . $GLOBALS['server']

View File

@ -29,7 +29,7 @@ class Node_Function extends Node
public function __construct($name, $type = Node::OBJECT, $is_group = false)
{
parent::__construct($name, $type, $is_group);
$this->icon = PMA_Util::getImage('b_routines.png');
$this->icon = PMA_Util::getImage('b_routines.png', __('Function'));
$this->links = array(
'text' => 'db_routines.php?server=' . $GLOBALS['server']
. '&amp;db=%2$s&amp;item_name=%1$s&amp;item_type=FUNCTION'

View File

@ -24,7 +24,7 @@ class Node_Function_Container extends Node
public function __construct()
{
parent::__construct(__('Functions'), Node::CONTAINER);
$this->icon = PMA_Util::getImage('b_routines.png');
$this->icon = PMA_Util::getImage('b_routines.png', __('Functions'));
$this->links = array(
'text' => 'db_routines.php?server=' . $GLOBALS['server']
. '&amp;db=%1$s&amp;token=' . $GLOBALS['token'],
@ -35,7 +35,7 @@ class Node_Function_Container extends Node
$new = PMA_NodeFactory::getInstance('Node', _pgettext('Create new function', 'New'));
$new->isNew = true;
$new->icon = PMA_Util::getImage('b_routine_add.png', '');
$new->icon = PMA_Util::getImage('b_routine_add.png', __('New'));
$new->links = array(
'text' => 'db_routines.php?server=' . $GLOBALS['server']
. '&amp;db=%2$s&amp;token=' . $GLOBALS['token']

View File

@ -29,7 +29,7 @@ class Node_Index extends Node
public function __construct($name, $type = Node::OBJECT, $is_group = false)
{
parent::__construct($name, $type, $is_group);
$this->icon = PMA_Util::getImage('b_index.png');
$this->icon = PMA_Util::getImage('b_index.png', __('Index'));
$this->links = array(
'text' => 'tbl_indexes.php?server=' . $GLOBALS['server']
. '&amp;db=%3$s&amp;table=%2$s&amp;index=%1$s'

View File

@ -24,7 +24,7 @@ class Node_Index_Container extends Node
public function __construct()
{
parent::__construct(__('Indexes'), Node::CONTAINER);
$this->icon = PMA_Util::getImage('b_index.png', '');
$this->icon = PMA_Util::getImage('b_index.png', __('Indexes'));
$this->links = array(
'text' => 'tbl_structure.php?server=' . $GLOBALS['server']
. '&amp;db=%2$s&amp;table=%1$s'
@ -37,7 +37,7 @@ class Node_Index_Container extends Node
$new = PMA_NodeFactory::getInstance('Node', _pgettext('Create new index', 'New'));
$new->isNew = true;
$new->icon = PMA_Util::getImage('b_index_add.png', '');
$new->icon = PMA_Util::getImage('b_index_add.png', __('New'));
$new->links = array(
'text' => 'tbl_indexes.php?server=' . $GLOBALS['server']
. '&amp;create_index=1&amp;added_fields=2'

View File

@ -29,7 +29,7 @@ class Node_Procedure extends Node
public function __construct($name, $type = Node::OBJECT, $is_group = false)
{
parent::__construct($name, $type, $is_group);
$this->icon = PMA_Util::getImage('b_routines.png');
$this->icon = PMA_Util::getImage('b_routines.png', __('Procedure'));
$this->links = array(
'text' => 'db_routines.php?server=' . $GLOBALS['server']
. '&amp;db=%2$s&amp;item_name=%1$s&amp;item_type=PROCEDURE'

View File

@ -24,7 +24,7 @@ class Node_Procedure_Container extends Node
public function __construct()
{
parent::__construct(__('Procedures'), Node::CONTAINER);
$this->icon = PMA_Util::getImage('b_routines.png');
$this->icon = PMA_Util::getImage('b_routines.png', __('Procedures'));
$this->links = array(
'text' => 'db_routines.php?server=' . $GLOBALS['server']
. '&amp;db=%1$s&amp;token=' . $GLOBALS['token'],
@ -35,7 +35,7 @@ class Node_Procedure_Container extends Node
$new = PMA_NodeFactory::getInstance('Node', _pgettext('Create new procedure', 'New'));
$new->isNew = true;
$new->icon = PMA_Util::getImage('b_routine_add.png', '');
$new->icon = PMA_Util::getImage('b_routine_add.png', __('New'));
$new->links = array(
'text' => 'db_routines.php?server=' . $GLOBALS['server']
. '&amp;db=%2$s&amp;token=' . $GLOBALS['token']

View File

@ -29,7 +29,25 @@ class Node_Table extends Node
public function __construct($name, $type = Node::OBJECT, $is_group = false)
{
parent::__construct($name, $type, $is_group);
$this->icon = PMA_Util::getImage('b_browse.png');
switch ($GLOBALS['cfg']['NavigationTreeDefaultTabTable']) {
case 'tbl_structure.php':
$title = __('Structure');
break;
case 'tbl_sql.php':
$title = __('SQL');
break;
case 'tbl_select.php':
$title = __('Search');
break;
case 'tbl_change.php':
$title = __('Insert');
break;
case 'sql.php':
$title = __('Browse');
break;
}
$this->icon = PMA_Util::getImage('b_browse.png', $title);
$this->links = array(
'text' => $GLOBALS['cfg']['DefaultTabTable']
. '?server=' . $GLOBALS['server']

View File

@ -40,7 +40,7 @@ class Node_Table_Container extends Node
$new = PMA_NodeFactory::getInstance('Node', _pgettext('Create new table', 'New'));
$new->isNew = true;
$new->icon = PMA_Util::getImage('b_table_add.png', '');
$new->icon = PMA_Util::getImage('b_table_add.png', __('New'));
$new->links = array(
'text' => 'tbl_create.php?server=' . $GLOBALS['server']
. '&amp;db=%2$s&amp;token=' . $GLOBALS['token'],

View File

@ -29,7 +29,7 @@ class Node_View extends Node
public function __construct($name, $type = Node::OBJECT, $is_group = false)
{
parent::__construct($name, $type, $is_group);
$this->icon = PMA_Util::getImage('b_views.png');
$this->icon = PMA_Util::getImage('b_views.png', __('View'));
$this->links = array(
'text' => 'sql.php?server=' . $GLOBALS['server']
. '&amp;db=%2$s&amp;table=%1$s&amp;pos=0'

View File

@ -24,7 +24,7 @@ class Node_View_Container extends Node
public function __construct()
{
parent::__construct(__('Views'), Node::CONTAINER);
$this->icon = PMA_Util::getImage('b_views.png', '');
$this->icon = PMA_Util::getImage('b_views.png', __('Views'));
$this->links = array(
'text' => 'db_structure.php?server=' . $GLOBALS['server']
. '&amp;db=%1$s&amp;token=' . $GLOBALS['token'],
@ -36,7 +36,7 @@ class Node_View_Container extends Node
$new = PMA_NodeFactory::getInstance('Node', _pgettext('Create new view', 'New'));
$new->isNew = true;
$new->icon = PMA_Util::getImage('b_view_add.png', '');
$new->icon = PMA_Util::getImage('b_view_add.png', __('New'));
$new->links = array(
'text' => 'view_create.php?server=' . $GLOBALS['server']
. '&amp;db=%2$s&amp;token=' . $GLOBALS['token'],