| Current Path : /home/quelfutuu/www/lchg/tmp/cache/calcul/b4/ |
| Current File : /home/quelfutuu/www/lchg/tmp/cache/calcul/b4/15.cache |
a:2:{s:9:"nom_cache";s:38:"b415c35600b8df23001e66ee1b7c5393.cache";s:6:"valeur";a:12:{s:9:"squelette";s:37:"html_b7f4ab2b4fd871aacd05000f919a5582";s:6:"source";s:44:"squelettes/article-PresentationArchives.html";s:11:"process_ins";s:3:"php";s:11:"invalideurs";a:1:{s:5:"cache";s:38:"b415c35600b8df23001e66ee1b7c5393.cache";}s:7:"entetes";a:1:{s:12:"X-Spip-Cache";i:86400;}s:5:"duree";i:0;s:5:"texte";s:12806:"
<!DOCTYPE html>
<!--.html dir="ltr" lang="fr" class="ltr fr no-js"-->
<html dir="ltr" lang="fr" class="ltr fr">
<head>
<meta charset="utf-8" />
<script type='text/javascript'>/*<![CDATA[*/(function(H){H.className=H.className.replace(/\bno-js\b/,'js')})(document.documentElement);/*]]>*/</script>
<title>Liste des archives - la Commune</title>
<link rel="stylesheet" href="lchg/lchgstyle.css" type="text/css" />
<script type="text/javascript" src="lchg/lchgscript.js" /></script>
<meta name="description" content=" Page spéciale mise en ligne par M. Possoz pour augmenter le sécurité. " />
<link rel="canonical" href="https://lchg.quelfutur.org/Liste-des-archives" />
<?php echo recuperer_fond( 'inclure/head', array('lang' => 'fr'), array("compil"=>array('squelettes/article-PresentationArchives.html','html_b7f4ab2b4fd871aacd05000f919a5582','',13,$GLOBALS['spip_lang'])), _request('connect') ?? '');
?>
</head>
<body class="pas_surlignable page_article">
<div class="page">
<?php echo recuperer_fond( 'inclure/header', array('lang' => 'fr'), array("compil"=>array('squelettes/article-PresentationArchives.html','html_b7f4ab2b4fd871aacd05000f919a5582','',20,$GLOBALS['spip_lang'])), _request('connect') ?? '');
?>
<?php echo recuperer_fond( 'inclure/nav', array_merge(array (
'id_article' => '15',
'type-page' => 'article',
'date' => '2026-06-22 11:19:33',
'date_default' => true,
'date_redac' => '2026-06-22 11:19:33',
'date_redac_default' => true,
),array('lang' => 'fr')), array("compil"=>array('squelettes/article-PresentationArchives.html','html_b7f4ab2b4fd871aacd05000f919a5582','',21,$GLOBALS['spip_lang'])), _request('connect') ?? '');
?>
<main class="main" role="main" style="width:100%; padding: 0.1em 0 0 0.1em">
<div class="wrapper hfeed" style="width:100%; background-color:#e4f6ce">
<div class="content hentry" id="content">
<p class="arbo"><a href="https://lchg.quelfutur.org/">Accueil</a> > <a href="-Archives-">Membres</a> > <strong class="on">Liste des archives</strong></p>
<div class="cartouche clearfix">
<h1 class="surlignable entry-title">Liste des archives</h1>
<!--.p class="info-publi"><abbr class="published" title="2000-11-06T18:57:00Z">lundi 6 novembre 2000</abbr></p-->
</div>
<!--. ===================================================================================================== -->
<div id="form_supprime"></div>
<div id="form_renomme"></div>
<!--.p class="right"><b><a href="aide.html">Aide</a> - <a href="https://lchg.quelfutur.org/spip.php?article16">Retour</a></b></p-->
<p class="right"><b><a href="aide.html">Aide</a></b></p>
<!--.h2>Fichiers de <b><i>la Commune</i></b></h2-->
<!--.h4>Présentation des fichiers</h4-->
<?php
setlocale(LC_TIME, 'fr_FR');
$relPath = "lchg/depot/";
$relTrashPath = "lchg/trash/";
if (isset($_POST['fichier_a_supprimer'])) {
$oldFullFilePath = $relPath . $_POST['fichier_a_supprimer'];
$newFullFilePath = TrashPath($oldFullFilePath);
// echo "old: " . $oldFullFilePath . ", new: $newFullFilePath";
// $trashList = getFileList($relTrashPath);
rename($oldFullFilePath, $newFullFilePath);
}
if (isset($_POST['fichier_a_renommer']) && isset($_POST['nouveau_nom'])) {
$newFullFilePath = $relPath . SupprimeAccentsEtBlancs($_POST['nouveau_nom']);
$oldFullFilePath = $relPath . $_POST['fichier_a_renommer'];
rename($oldFullFilePath, $newFullFilePath);
}
// display file upload form
if (!isset($_POST['submit'])) { ?>
<!--.form enctype="multipart/form-data" action="<?php echo $_SERVER['PHP_SELF']?>" method="post"-->
<form enctype="multipart/form-data" action="https://lchg.quelfutur.org/Liste-des-archives" method="post">
<!--.input type="hidden" name="MAX_FILE_SIZE" value="5000000" /> Choisir un fichier à téléverser
<!--.input type="file" name="data"/> <!--.br /-->
<!--.input type="submit" name="submit" value="Téléverser le fichier" /-->
</form><br>
<?php
}
else {
foreach($_FILES as &$file) $file['name'] = SupprimeAccentsEtBlancs($file['name']);
unset($file);
// check for existing file
$dirList = getFileList($relPath);
foreach($dirList as $file) {
if ($_FILES['data']['name'] == $file['basename']) my_die("\nERREUR: le fichier '".$file['basename']."' est déjà présent !");
}
// check uploaded file size
if ($_FILES['data']['size'] == 0) my_die("\nERREUR: Absence de fichier, fichier vide ou fichier trop gros (> 5 Mo) !");
// check if file type is allowed (optional)
$allowedFileTypes = array(
"application/vnd.oasis.opendocument.spreadsheet",
"application/vnd.oasis.opendocument.text",
"application/vnd.openxmlformats-officedocument.wordprocessingml.document",
"application/msword",
"image/jpg", "image/jpeg",
"application/pdf",
"text/plain"
// , "image/png", "image/gif", "image/jpg", "image/jpeg", "image/pjpeg"
);
if (!in_array($_FILES['data']['type'], $allowedFileTypes)) {
my_die("ERREUR: '".$file['basename']."',type de fichier non accepté.");
} // check if this is a valid upload
if (!is_uploaded_file($_FILES['data']['tmp_name'])) {
my_die("ERREUR: Le téléversement a échoué");
} // set the name of the target directory
move_uploaded_file($_FILES['data']['tmp_name'], $relPath.$_FILES['data']['name']) or my_die("Impossible de copier le fichier");
echo '- Fichier <i>'.$_FILES['data']['name'].'</i> correctement enregistré : <b><a href="https://lchg.quelfutur.org/Liste-des-archives"> Continuer...</a></b>';
}
// Liste des fichiers est déjà dans le titre de l'article
// echo "<h4>Liste des fichiers</h4>";
//IF THE sort FLAG HASN'T BEEN SET YET, SET THE DEFAULT
$dirList = getFileList($relPath);
if(!isset($_GET['triPar'])) {
$_GET['triPar'] = 'nom';
}
switch($_GET['triPar']) {
case 'taille' : $sortres = usort($dirList, 'compsize'); break;
case 'nom' : $sortres = usort($dirList, 'compname'); break;
case 'date' : $sortres = usort($dirList, 'compdate'); break;
}
$sortOnName = '<a href="https://lchg.quelfutur.org/Liste-des-archives?triPar=nom">Nom</a>';
$sortOnDate = '<a href="https://lchg.quelfutur.org/Liste-des-archives?triPar=date">Date de mise en ligne</a>';
$sortOnSize = '<a href="https://lchg.quelfutur.org/Liste-des-archives?triPar=taille">Taille</a>';
// output file list in HTML TABLE format
echo "<table border=\"1\" style=width:100%>\n";
echo "<thead>\n";
echo "<tr><th>$sortOnName</th><th>$sortOnSize</th><th>$sortOnDate</th></tr>\n";
echo "</thead>\n";
echo "<tbody>\n";
foreach($dirList as $file) {
// foreach($sortres as $file) {
echo "<tr>\n";
echo "<td><a href=\"$relPath{$file['basename']}\" type=\"{$file['type']}\">{$file['basename']}</a></td>\n";
if ($file['size'] > 999999) $fsize = number_format($file['size']/1000000, 1, ',', ' ')." Mo";
elseif ($file['size'] > 999) $fsize = number_format($file['size']/1000, 1, ',', ' ')." ko";
else $fsize = $file['size']." octets";
echo "<td class=\"center\">$fsize </td>";
echo "<td > " . utf8_encode(strftime('%A %d %B %Y %H:%M', $file['lastmod'])) . "</td>\n";
// echo "<td > " . $file['lastmod'] . "</td>\n";
// echo '<td> <div class="dropdown"> <button onclick="menudisplay(\'', $file['basename'], '\')" class="dropbtn"> Modifier </button>';
// echo '<div id="Menu-', $file['basename'], '" class="dropdown-content"> <a href="" onclick="renomme(\'', $file['basename'], '\', event)">Renommer</a>';
// echo '<a href="" onclick="supprime(\'', $file['basename'], '\', event)">Supprimer</a> </div>';
// echo '</div></td>';
echo "</tr>\n";
}
echo "</tbody>\n";
echo "</table>\n\n";
function getFileList($dir) {
// array to hold return value
$retval = array();
// add trailing slash if missing
if(substr($dir, -1) != "/") $dir .= "/";
// open pointer to directory and read list of files
$d = @dir($dir) or my_die("ERREUR: répertoire inaccessible, contacter l'administrateur.");
while(false !== ($entry = $d->read())) {
// skip hidden files
if($entry[0] == ".") continue;
if(is_dir("$dir$entry")) {
$retval[] = array(
"name" => "$dir$entry",
"basename" => basename("$dir$entry"),
"type" => filetype("$dir$entry"),
"size" => 0,
"lastmod" => filemtime("$dir$entry")
);
} elseif(is_readable("$dir$entry")) {
$retval[] = array(
"name" => "$dir$entry",
"basename" => basename("$dir$entry"),
"type" => mime_content_type("$dir$entry"),
"size" => filesize("$dir$entry"),
"lastmod" => filemtime("$dir$entry")
);
}
}
$d->close();
return $retval;
}
function compname($filea, $fileb) {
return(strcmp(mb_strtoupper($filea['basename']), mb_strtoupper($fileb['basename'])));
}
function compsize($filea, $fileb) {
// return($filea['size'] > $fileb['size'] ? 0 : 1);
return($filea['size'] <=> $fileb['size']);
}
function compdate($filea, $fileb) {
// return($filea['lastmod'] > $fileb['lastmod'] ? 0 : 1);
return($filea['lastmod'] <=> $fileb['lastmod']);
}
function my_die($message) {
die($message . ' <b><a href="' . $_SERVER['PHP_SELF'] . '">Retour...</a></b>');
}
function SupprimeAccentsEtBlancs($str, $encoding='utf-8') {
$str = str_replace(" ", "_", $str);
$str = str_replace("'", "_", $str);
// transformer les caractères accentués en entités HTML
$str = htmlentities($str, ENT_NOQUOTES, $encoding);
$str = preg_replace('#&([A-za-z])(?:acute|grave|cedil|circ|orn|ring|slash|th|tilde|uml);#', '\1', $str);
// Remplacer les ligatures tel que : , Æ ...
// Exemple "œ" => "oe"
$str = preg_replace('#&([A-za-z]{2})(?:lig);#', '\1', $str);
// Supprimer tout le reste
$str = preg_replace('#&[^;]+;#', '', $str);
return $str;
}
function TrashPath($fullFilePath) {
global $relTrashPath;
$trashList = getFileList($relTrashPath);
$count = 1;
$pathParts = pathinfo($fullFilePath);
$newFullFilePath = $relTrashPath . $pathParts['basename'];
while(FileExists($trashList, $newFullFilePath)) {
$tempFileName = sprintf("%s (%d)", $pathParts['filename'], $count++);
$newFullFilePath = $relTrashPath . $tempFileName;
}
return $newFullFilePath;
}
function FileExists($trashList, $fullFilePath) {
foreach ($trashList as $file) {
if ($fullFilePath == $file['name']) return true;
}
return false;
}
?>
<!--. ===================================================================================================== -->
<div class="texte surlignable clearfix"><center>Page spéciale mise en ligne par M. Possoz pour augmenter le sécurité.</center></div>
<?php echo recuperer_fond( 'inclure/forum', array('id_article' => '15',
'lang' => 'fr'), array("compil"=>array('squelettes/article-PresentationArchives.html','html_b7f4ab2b4fd871aacd05000f919a5582','',247,$GLOBALS['spip_lang'])), _request('connect') ?? '');
?>
</div><!--.content-->
</div><!--.wrapper-->
<!--.aside class="aside" role="complementary">
<?php echo recuperer_fond( 'inclure/navsub', array('id_rubrique' => '6',
'lang' => 'fr'), array("compil"=>array('squelettes/article-PresentationArchives.html','html_b7f4ab2b4fd871aacd05000f919a5582','',256,$GLOBALS['spip_lang'])), _request('connect') ?? '');
?>
<?php
include_once("./" . _DIR_RACINE . "ecrire/balise/formulaire_.php");
if ($lang_select = "fr") $lang_select = lang_select($lang_select);
inserer_balise_dynamique(balise_FORMULAIRE__dyn('FORMULAIRE_RECHERCHE'), array('squelettes/article-PresentationArchives.html', 'html_b7f4ab2b4fd871aacd05000f919a5582', '_principale', 257, 'fr'));
if ($lang_select) lang_select();
?>
<div class="menu">
<h2>Dans la même rubrique</h2>
<ul>
<li><a href="Liste-des-archives" class="on">Liste des archives</a></li>
<li><a href="Aide">Aide</a></li>
</ul>
</div>
<div class="menu">
<h2>Mots-clés</h2>
<ul>
<li><a href="+-PresentationArchives-+" rel="tag">PresentationArchives</a></li>
</ul>
</div></aside><!--.aside-->
</main><!--.main-->
<?php echo recuperer_fond( 'inclure/footer', array_merge(array (
'id_article' => '15',
'type-page' => 'article',
'date' => '2026-06-22 11:19:33',
'date_default' => true,
'date_redac' => '2026-06-22 11:19:33',
'date_redac_default' => true,
),array('self' => 'Liste-des-archives',
'lang' => 'fr')), array("compil"=>array('squelettes/article-PresentationArchives.html','html_b7f4ab2b4fd871aacd05000f919a5582','',268,$GLOBALS['spip_lang'])), _request('connect') ?? '');
?>
</div><!--.page-->
</body>
</html>
";s:5:"notes";s:0:"";s:8:"contexte";a:6:{s:10:"id_article";s:2:"15";s:9:"type-page";s:7:"article";s:4:"date";s:19:"2026-06-22 11:19:33";s:12:"date_default";b:1;s:10:"date_redac";s:19:"2026-06-22 11:19:33";s:18:"date_redac_default";b:1;}s:12:"lastmodified";i:1782119973;s:2:"gz";b:0;s:3:"sig";i:1568430156;}}