75 lines
3.4 KiB
HTML
Executable File
75 lines
3.4 KiB
HTML
Executable File
<!DOCTYPE html>
|
|
<html lang="fr">
|
|
|
|
<? include('blocks/d.head.html'); ?>
|
|
|
|
<body>
|
|
|
|
<? include('blocks/d.nav.html'); ?>
|
|
|
|
<section id="wiki_files">
|
|
<h1><?=$head['title']?></h1>
|
|
|
|
<p class="subtitle">Fichiers attachés <?=$first?> à <?=$last?> sur les <?=$filenb?> présents</p>
|
|
|
|
<br>
|
|
<br>
|
|
|
|
<form action="<?=$config['rel_root_folder']?>admin/wiki-files/upload/" method="post" enctype="multipart/form-data" id="send_file">
|
|
<div>
|
|
<label for="file">Envoyer un fichier :</label>
|
|
<input type="file" id="file" name="file">
|
|
</div>
|
|
<input type="submit" value="Envoyer">
|
|
</form>
|
|
|
|
|
|
<table>
|
|
<tr class="first">
|
|
<th>
|
|
<a href="<?=$config['rel_root_folder']?>admin/wiki-files/<?=$page+1?>?orderby=name&order=<?=$order=='ASC'?'DESC':'ASC'?>">Nom</a>
|
|
<?=$orderby=='name'?$order=='ASC'?'<i class="fas fa-caret-down" aria-hidden="true"></i>':'<i class="fas fa-caret-up" aria-hidden="true"></i>':''?>
|
|
</th>
|
|
<th>
|
|
<a href="<?=$config['rel_root_folder']?>admin/wiki-files/<?=$page+1?>?orderby=type&order=<?=$order=='ASC'?'DESC':'ASC'?>">Type</a>
|
|
<?=$orderby=='type'?$order=='ASC'?'<i class="fas fa-caret-down" aria-hidden="true"></i>':'<i class="fas fa-caret-up" aria-hidden="true"></i>':''?>
|
|
</th>
|
|
<th>
|
|
<a href="<?=$config['rel_root_folder']?>admin/wiki-files/<?=$page+1?>?orderby=size&order=<?=$order=='ASC'?'DESC':'ASC'?>">Taille</a>
|
|
<?=$orderby=='size'?$order=='ASC'?'<i class="fas fa-caret-down" aria-hidden="true"></i>':'<i class="fas fa-caret-up" aria-hidden="true"></i>':''?>
|
|
</th>
|
|
<th>
|
|
<a href="<?=$config['rel_root_folder']?>admin/wiki-files/<?=$page+1?>?orderby=creation_date&order=<?=$order=='ASC'?'DESC':'ASC'?>">Date de création</a>
|
|
<?=$orderby=='creation_date'?$order=='ASC'?'<i class="fas fa-caret-down" aria-hidden="true"></i>':'<i class="fas fa-caret-up" aria-hidden="true"></i>':''?>
|
|
</th>
|
|
<? if ($user->rankIsHigher("administrator")) { ?>
|
|
<th>Suppression</th>
|
|
<? } ?>
|
|
</tr>
|
|
<? foreach (array_slice($files, $first-1, $rows_per_pages, true) as $file) { ?>
|
|
<tr>
|
|
<td>
|
|
<a href="<?=$config['rel_root_folder']?>medias/wiki/<?=$file['name']?>"><?=$file['name']?></a>
|
|
</td>
|
|
<td><i class='fas <?=getFontAwesomeIcon($file['type'])?>'></i> <?=$file['type']?></td>
|
|
<td><?=formatBytes($file['size'], $user->locale)?></td>
|
|
<td><? echo datefmt_format($user->date_format,date_create($file['creation_date'], new DateTimeZone("UTC"))) ?></td>
|
|
<? if ($user->rankIsHigher("administrator")) { ?>
|
|
<td class="center">
|
|
<a href="<?=$config['rel_root_folder']?>admin/wiki-files/delete/<?=$file['name']?>?orderby=<?=$orderby?>&order=<?=$order?>" onclick="return confirm('Es-tu sûr de vouloir supprimer ?');"><span class="external-link"><i class="fas fa-trash"></i></span></a>
|
|
</td>
|
|
<? } ?>
|
|
</tr>
|
|
<? } ?>
|
|
</table>
|
|
<div class="pagebuttons">
|
|
<? if ($page != 0) { ?><a class="previous" href="<?=$config['rel_root_folder']?>admin/wiki-files/<?=$page?>?orderby=<?=$orderby?>&order=<?=$order?>"><i class="fas fa-chevron-left fa-fw"></i></a><? }
|
|
if (($page+1)*$rows_per_pages < $filenb) { ?><a class="next" href="<?=$config['rel_root_folder']?>admin/wiki-files/<?=$page+2?>?orderby=<?=$orderby?>&order=<?=$order?>"><i class="fas fa-chevron-right fa-fw"></i></a><? } ?>
|
|
</div>
|
|
|
|
</section>
|
|
|
|
<? include('blocks/d.footer.html'); ?>
|
|
|
|
</body>
|
|
</html> |