7 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
45
46
47
48
49
50
51
52
53
#!/usr/bin/perl -w
use strict;
use DBI;
use CGI::Carp qw(fatalsToBrowser);
use CGI qw(param);
print "Content-type: text/html\n\n";
my $sendmail = "/usr/lib/sendmail";
my $an_name = "Martin Alter";
my $mail_adr_an = '****';
my $von_name = "Martin Alter";
my $mail_adr_von = '****';
my $betreff = "Hallo";
my $text = "Hallo wenn ich das hier lese bin ich zufrieden";
my $dbh = DBI -> connect("DBI:mysql:jung3r","jung3r","******")or die "connection failed $DBI::errstr";
my $auswertung = $dbh -> prepare("SELECT * FROM bilder");
$auswertung -> execute or die $auswertung -> errstr;
$dbh -> disconnect();
open (MAIL, "|$sendmail -t") or die ("Fehler $!");
print MAIL qq|To: "$an_name" <$mail_adr_an>\n|;
print MAIL qq|From: "$von_name" <$mail_adr_von>\n|;
print MAIL qq|Subject: $betreff\n\n|;
print MAIL "Content-Type: text/html\n\n";
print MAIL " charset=\"iso-8859-1\"\n";
print MAIL "Content-Transfer-Encoding: quoted-printable\n\n";
print MAIL "<html>";
print MAIL "<head>";
print MAIL "<title>Start</title>";
print MAIL '<meta name="author" content="alter">';
print MAIL "</head>";
print MAIL '<body text="#000000" bgcolor="#80FF80" link="#FF0000" alink="#FF0000" vlink="#FF0000">';
print MAIL "<table border=1>";
print MAIL "<tr>";
print MAIL "<td><b>Vorname</b></td><td><b>Name</b></td><td><b>Abteilung</b></td><td><b>Zimmer</b></td>";
print MAIL &schleife;
print MAIL "</body>";
print MAIL "</html>";
close (MAIL) or die ("Fehler beim Schließen. Grund : $!");
sub schleife {
while(my $data = $auswertung -> fetchrow_hashref) {
print MAIL "<tr>";
print MAIL "<td>$$data{'Vorname'}</td>";
print MAIL "<td>$$data{'name'}</td>";
print MAIL "<td>$$data{'Abteilung'}</td>";
print MAIL "<td>$$data{'zimmer'}</td>";
print MAIL "</tr>";
}
}
1
2
3
4
5
6
Content-Type: text/html
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable
<html><head><title>Start</title><meta name="author" content="alter"></head><body text="#000000" bgcolor="#80FF80" link="#FF0000" alink="#FF0000" vlink="#FF0000"><table border=1><tr><td><b>Vorname</b></td><td><b>Name</b></td><td><b>Abteilung</b></td><td><b>Zimmer</b></td><tr><td>werwe</td><td>ewrw</td><td>wer</td><td>wer</td></tr><tr><td>aaa</td><td>aa</td><td>aaa</td><td>aaa</td></tr><tr><td>aaa</td><td>aaa</td><td>aaa</td><td>aaa</td></tr></body></html>
1
2
Can't locate MIME/Lite/HTML.pm in @INC (@INC contains: ./library ./library/Lite.pm /usr/lib/perl5/5.8.7/x86_64-linux-thread-multi /usr/lib/perl5/5.8.7 /usr/lib/perl5/site_perl/5.8.7/x86_64-linux-thread-multi /usr/lib/perl5/site_perl/5.8.7 /usr/lib/perl5/site_perl /usr/lib/perl5/vendor_perl/5.8.7/x86_64-linux-thread-multi /usr/lib/perl5/vendor_perl/5.8.7 /usr/lib/perl5/vendor_perl .) at /srv/www/virtual/b4ckb0n3.de/jung3r/cgi-bin/test_mail.pl line 8.
BEGIN failed--compilation aborted at /srv/www/virtual/b4ckb0n3.de/jung3r/cgi-bin/test_mail.pl line 8.
Alter+2008-02-27 09:38:52--und soweit ich das verstanden habe heist es das lite nicht auf dem server ist und ich habe keine rechte dafür...
7 Einträge, 1 Seite |