Skip to content
Snippets Groups Projects
Commit 806d77a0 authored by Andreas Gohr's avatar Andreas Gohr
Browse files

Display fileicons in Media Dialog

darcs-hash:20051118154544-7ad00-44682b3e800a616d74eacb61dfa8c6dc5a1a336b.gz
parent bb406e63
No related branches found
No related tags found
No related merge requests found
......@@ -667,8 +667,15 @@ function tpl_mediafilelist(){
ptln('<ul>',2);
foreach($data as $item){
if(!$item['isimg']){
// add file icons
list($ext,$mime) = mimetype($item['file']);
$class = preg_replace('/[^_\-a-z0-9]+/i','_',$ext);
$class .= ' class="mediafile mf_'.$class.'"';
}
ptln('<li>',4);
ptln('<a href="javascript:mediaSelect(\':'.$item['id'].'\')">'.
ptln('<a href="javascript:mediaSelect(\':'.$item['id'].'\')"'.$class.'>'.
utf8_decodeFN($item['file']).
'</a>',6);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment