metanohi-misc-subsites/subsites/words/index.php

29 lines
704 B
PHP

<?php
//WTFPL 2.0
header('Content-type: text/plain; charset=UTF-8');
date_default_timezone_set('Europe/Copenhagen');
echo
'******************************************************
*** THIS IS NOT A (MICRO)BLOG. ************************
*******************************************************
Source code: projects.metanohi.name/misc/words.tar.gz *
*******************************************************
';
$d='';for ($i=0;$i<19;$i++) $d.= '-';
$files = scandir('data');
$files = array_reverse($files);
foreach ($files as $x) {
$n = "data/$x";
if (is_file($n)) {
$f = fopen($n, 'r');
$t = fread($f, filesize($n));
fclose($f);
echo "$d\n" . date('Y.m.d H:i:s', $x+0) . "\n$d\n$t\n\n";
}
}
?>