initial commit
This commit is contained in:
commit
64ad93f61d
11 files changed
+412
No files matched your search
@@ -0,0 +1,31 @@
|
||||
---
|
||||
layout: default
|
||||
permalink: /
|
||||
---
|
||||
|
||||
<div class="publication">
|
||||
<div class="pub-header">
|
||||
|
||||
<?php
|
||||
// Pega todos os arquivos .txt no diretório atual
|
||||
$files = glob('assets/data/*.txt');
|
||||
|
||||
// Inicia a lista não ordenada
|
||||
echo "<ul>";
|
||||
|
||||
foreach ($files as $file) {
|
||||
// Remove a extensão .txt do nome do arquivo
|
||||
$filenameWithoutExtension = basename($file, '.txt');
|
||||
|
||||
// Cria o link com o nome do arquivo na query string
|
||||
$link = "/alice_index/file_index.php?filetype=" . urlencode($filenameWithoutExtension);
|
||||
|
||||
// Cria o item da lista com o link
|
||||
echo "<li><a href=\"$link\">$filenameWithoutExtension</a></li>";
|
||||
}
|
||||
|
||||
// Fecha a lista não ordenada
|
||||
echo "</ul>";
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
Reference in new issue
Block a user