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
#!"C:\Program Files (x86)\Active Perl 5.20.1\bin\perl.exe"
use CGI;
use CGI::CARP qw(fatalsToBrowser);
my $cgi = new CGI;
my $act = $cgi->param('act');
if($act eq "Test2") { Test2(); }
else { Test1(); }
sub Test1 {
print "Content-type:text/html\r\n\r\n";
print '<HTML>';
print '<HEAD>';
print '<TITLE>EPROM - Monitoring</TITLE>';
print '</HEAD>';
print '<BODY BGCOLOR = "#FFFFFF">';
print '<form method="post" action="http://127.0.0.1/cgi-bin/test.pl?act=Test2">';
print '<input type="submit" value="Führe Test2 aus">';
print '</form>';
print '</BODY>';
print '</HTML>';
}
sub Test2 {
print "Content-type:text/html\r\n\r\n";
print 'Dies ist die Bestätigung, dass das Script funktioniert';
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
sub Test1 {
print "Content-type:text/html\r\n\r\n";
print '<HTML>';
print '<HEAD>';
print '<TITLE>EPROM - Monitoring</TITLE>';
print '</HEAD>';
print '<BODY BGCOLOR = "#FFFFFF">';
print '<form method="post" action="http://127.0.0.1/cgi-bin/test.pl">';
print '<input type="submit" value="Führe Test2 aus">';
print '<input type="hidden" name="act" value="Test2">';
print '</form>';
print '</BODY>';
print '</HTML>';
}