Skip to content

Commit

Permalink
XHTML validation fix.
Browse files Browse the repository at this point in the history
provide "alt" property on icons and attached images


git-svn-id: http://mantisbt.svn.sourceforge.net/svnroot/mantisbt/trunk@4429 f5dc347c-c33d-0410-90a0-b07cc1902cb9
  • Loading branch information
giallu committed Jul 12, 2007
1 parent bddc51f commit 9b04b73
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 5 deletions.
7 changes: 4 additions & 3 deletions core/file_api.php
Expand Up @@ -6,7 +6,7 @@
# See the README and LICENSE files for details

# --------------------------------------------------------
# $Id: file_api.php,v 1.80 2007-07-06 22:29:53 giallu Exp $
# $Id: file_api.php,v 1.81 2007-07-12 08:13:02 giallu Exp $
# --------------------------------------------------------

$t_core_dir = dirname( __FILE__ ).DIRECTORY_SEPARATOR;
Expand Down Expand Up @@ -255,14 +255,15 @@ function swap_content( span ) {
}

$t_preview_style = 'style="' . $t_preview_style . '"';
$t_title = file_get_field( $v_id, 'title' );

PRINT "<br />$t_href_start<img $t_preview_style src=\"file_download.php?file_id=$v_id&amp;type=bug\" />$t_href_end";
PRINT "\n<br />$t_href_start<img alt=\"$t_title\" $t_preview_style src=\"file_download.php?file_id=$v_id&amp;type=bug\" />$t_href_end";
$image_previewed = true;
}
}

if ( $i != ( $num_files - 1 ) ) {
PRINT '<br />';
PRINT "<br />\n";
}
}
}
Expand Down
5 changes: 3 additions & 2 deletions core/print_api.php
Expand Up @@ -6,7 +6,7 @@
# See the README and LICENSE files for details

# --------------------------------------------------------
# $Id: print_api.php,v 1.169 2007-07-09 22:41:23 giallu Exp $
# $Id: print_api.php,v 1.170 2007-07-12 08:13:02 giallu Exp $
# --------------------------------------------------------

$t_core_dir = dirname( __FILE__ ).DIRECTORY_SEPARATOR;
Expand Down Expand Up @@ -1528,7 +1528,8 @@ function print_file_icon( $p_filename ) {
}

$t_name = $t_file_type_icons[$ext];
PRINT '<img src="' . config_get( 'path' ) . 'images/fileicons/'. $t_name . '" width="16" height="16" border="0" />';
PRINT '<img src="' . config_get( 'path' ) . 'images/fileicons/'. $t_name .
'" alt="' . $ext . ' file icon" width="16" height="16" border="0" />';
}

# --------------------
Expand Down

0 comments on commit 9b04b73

Please sign in to comment.