#!/usr/bin/perl

use strict;
use warnings;

$| = 1;

# ----------- Beginn Konfiguration --------------
my $Filename = "./ausreden.txt";
# ------------ Ende Konfiguration ---------------

my @excuses = ();
my $thisexcuse = '';

open(DAT, $Filename) || print "Argh! Can't read the excuse file!\n";
@excuses = <DAT>;
close(DAT);
srand(time);
$thisexcuse = $excuses[(rand(5000)*$$)%($#excuses)];

# kein Formular, kein sonstwas... 
print "Content-type: text/html\n\n";

print qq~
<HTML><HEAD>
<TITLE>Entschuldigungen f&uuml;r den Admin</TITLE>
<DIV ALIGN="CENTER">
<BR><BR>
<TABLE BORDER="3" CELLPADDING="20" CELLSPACING="0" BGCOLOR="#FFAA80">
<TR><TD ALIGN="CENTER">
<H1>Entschuldigungen f&uuml;r den Administrator</H1>
<FONT SIZE="+2">
Das Problem ist:
<UL><B>$thisexcuse</B></UL>
</FONT>
</TD></TR></TABLE>
</DIV>
</BODY>
</HTML>
~;

