summaryrefslogtreecommitdiff
path: root/program/include
diff options
context:
space:
mode:
authorthomascube <thomas@roundcube.net>2005-10-13 22:21:10 +0000
committerthomascube <thomas@roundcube.net>2005-10-13 22:21:10 +0000
commit14eafe4d89056b6a5bd383f15c2ca1de647f1d4e (patch)
tree2f5d2126ce09fbbb0c692bd07fdb8728e3bbc27d /program/include
parent455c2bd934e0dd708244e9e1c9fc7acd5d7b37e7 (diff)
Fixed bug #1325050; added alt-texts for IE
Diffstat (limited to 'program/include')
-rw-r--r--program/include/main.inc11
1 files changed, 9 insertions, 2 deletions
diff --git a/program/include/main.inc b/program/include/main.inc
index 2e5be7b0e..1c413bb80 100644
--- a/program/include/main.inc
+++ b/program/include/main.inc
@@ -671,7 +671,7 @@ function rcube_xml_command($command, $str_attrib, $a_attrib=NULL)
// create and register a button
function rcube_button($attrib)
{
- global $CONFIG, $OUTPUT, $JS_OBJECT_NAME;
+ global $CONFIG, $OUTPUT, $JS_OBJECT_NAME, $BROWSER;
static $sa_buttons = array();
static $s_button_count = 100;
@@ -728,7 +728,14 @@ function rcube_button($attrib)
if ($attrib['alt'])
$attrib['alt'] = rep_specialchars_output(rcube_label($attrib['alt']));
-
+
+ // set title to alt attribute for IE browsers
+ if ($BROWSER['ie'] && $attrib['title'] && !$attrib['alt'])
+ {
+ $attrib['alt'] = $attrib['title'];
+ unset($attrib['title']);
+ }
+
// add empty alt attribute for XHTML compatibility
if (!isset($attrib['alt']))
$attrib['alt'] = '';