This commit is contained in:
2024-10-14 00:08:40 +02:00
parent dbfba56f66
commit 1462d52e13
4572 changed files with 2658864 additions and 0 deletions

View File

@@ -0,0 +1,47 @@
#!/bin/perl
use Mysql;
use strict;
use CGI qw(:standard);
my $save=param('save');
my $dd = param('day');
my $mm = param('month');
my $yy = param('year');
my $ftag = param('ftag');
my $datum;
print header();
print "<html>\n";
print "<head>\n";
print "</head>\n";
print "<body>\n";
print "Datumsformat dd-mm-yyyy. Ist dd oder mm kleiner als 10,<br>muß eine führende 0 eingegeben werden.<br>\n";
print "Bei Eingabe eines ungültigen Datums wird 00-00-0000 gespeichert!<br><br>\n";
my $dbh = DBI->connect("DBI:mysql:database=c2;host=localhost",'root','', {RaiseError => 1});
if ($save eq "") {
my $sth = $dbh->prepare("select description,datum from not_run_on order by datum");
$sth->execute;
#print "<form action='notrunon.pl'>\n";
print "<table>\n";
while (my $ref = $sth->fetchrow_arrayref()) {
my ($yy,$mm,$dd) = split /-/,$ref->[1];
print "<tr><form action='notrunon.pl'><input type='hidden' name='ftag' value='$ref->[0]'><td>$ref->[0]</td><td><input size='1' type='text' name='day' value='$dd'></td><td><input size='1' type='text' name='month' value='$mm'></td><td><input size='3' type='text' name='year' value='$yy'></td><td><input type='submit' name='save' value='Speichern'></td></form></tr>\n";
}
print "</table>\n";
#print "</form>\n";
}
if ($save eq "Speichern") {
$datum="$yy" . "-" . "$mm" . "-" . "$dd";
$dbh->do("update not_run_on set datum='$datum' where description='$ftag'");
print "<br><br>Gespeichert\n";
#print "$ftag $dd $mm $yy";
}
print "</body>\n";
print "</html>\n";