<?php
echo "<select name='article' onchange='...'>";
while ($numpost<50)
{
if (file_exists("Fichiers txt/post$numpost.txt")==1)
{
$filename = "Fichiers txt/post$numpost.txt";
$contenupost = file_get_contents($filename);
$separateur = "*@*";
$tableau = explode($separateur, $contenupost);
setlocale(LC_TIME, "fr");
$datefic = strftime('%d %B %Y', filemtime($filename));
$heurfic = date('H:i', filemtime($filename));
$option= "$tableau[0] le $datefic à $heurfic";
echo "<option value='post$numpost'>$option</option>";
}
$numpost=$numpost+1;
}
echo "</select>";
?>
<textarea rows="10" cols="70" name="description">contenu de post$numpost</textarea>
Partager