6 Einträge, 1 Seite |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44
use strict; use CGI::Carp qw(fatalsToBrowser); my $Verzeichnis = "D:/CM/xampp"; opendir(DIR, $Verzeichnis) || die "$Verzeichnis: $!"; my @Dateien = readdir(DIR); closedir(DIR); print "Content-type: text/html\n\n"; print '<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">', "\n"; print "<html><head><title>Index</title></head><body>\n"; print "<style type=\"text/css\">"; print "h1 { color:red; font:arial; font-size:48px; }"; print "td { color:black; font:arial; font-size:16px; }"; print "</style>"; print $0; print "<form action=\"http://localhost/perl/cc_index.pl/\" method=\"post\">"; print "<table>"; print " <tr>"; print " <td width=\"300\">Dateiname</td>"; print " <td width=\"300\">Typ</td>"; print " </tr>"; foreach(@Dateien) { print "<input type=\"hidden\" name=\"Datei\" value=\"$_\">"; print " <tr>"; print " <td width=\"300\">$_</td>"; if(-d $_) { print "<td width=\"300\"><input type=\"submit\" value=\"weiter\"></td>"; } else { print "<td width=\"300\"><img src=\"D:\/CM\/bilder\/Reader-32.pdf\" width=\"14\" height=\"10\" alt=\"PDF\"> <br></td>"; } print " </tr>"; } print "</table>"; print "</form>"; print "</body></html>\n";
6 Einträge, 1 Seite |