Skip to content

Commit

Permalink
MDL-25840 blog - fixed broken image file image attachment display
Browse files Browse the repository at this point in the history
  • Loading branch information
Aparup Banerjee committed Apr 27, 2011
1 parent 4452ed6 commit 20b5038
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion blog/locallib.php
Expand Up @@ -517,7 +517,7 @@ public function print_attachments($return=false) {


} else { } else {
if (in_array($type, array('image/gif', 'image/jpeg', 'image/png'))) { // Image attachments don't get printed as links if (in_array($type, array('image/gif', 'image/jpeg', 'image/png'))) { // Image attachments don't get printed as links
$imagereturn .= "<br />" . $OUTPUT->pix_icon($ffurl, $filename); $imagereturn .= '<br /><img src="'.$ffurl.'" alt="" />';
} else { } else {
$imagereturn .= html_writer::link($ffurl, $image); $imagereturn .= html_writer::link($ffurl, $image);
$imagereturn .= format_text(html_writer::link($ffurl, $filename), FORMAT_HTML, array('context'=>$syscontext)); $imagereturn .= format_text(html_writer::link($ffurl, $filename), FORMAT_HTML, array('context'=>$syscontext));
Expand Down

0 comments on commit 20b5038

Please sign in to comment.