Abend Struppi
Ich habe mir noch mal die Mühe gemacht, und alles so wie du empfiehlst eingegeben. Leider geht es auf deine Weise nicht. Ich habe das ausprobiert, weil meine Version auch nur unter der standartmethode läuft. Sobald ich use strict eingebe geht nichts mehr. Auch dein header mit :: geht bei mir nicht. Er will den Pfeil ->
Nachfolgend mal ausnamsweise den ganzen Code. Sind noch alte Skalare drin, die ich aber wahrscheinlich im laufe der Bestellung eh brauchen werde. Du kannst dir den Kopf und den Mittelteil ansehen, weiter unten ist eh nur HTML-Stuff. Es läuft, ind macht mir auch keine Fehlermeldung. Ah, wegen der Funktion ober CGI::Cookie und CGI::cookie ---> Mein Perl will Cookie groß geschrieben. Klein meckert er no such xxx fund usw...
Hier der Vorläufige Perl-Code:
#!/usr/bin/perl -w
use Fcntl ':flock';
use CGI -no_xhtml;
use CGI::Carp qw(fatalsToBrowser warningsToBrowser);
use CGI qw(:standard);
use CGI::Cookie;
#######################
Skalare Adressmaske
#######################
my $task = CGI::param('task') || 'X';
my $menge01 = CGI::param('menge01') || 'X';
my $artikel01 = CGI::param('artikel01') || 'X';
my $anrede = CGI::param('anrede') || 'X';
my $vorname = CGI::param('vorname') || 'X';
my $name = CGI::param('name') || 'X';
my $geboren = CGI::param('geboren') || 'X';
my $hausnummer = CGI::param('hausnummer') || 'X';
my $land = CGI::param('land') || 'X';
my $plz = CGI::param('plz') || 'X';
my $ort = CGI::param('ort') || 'X';
my $telefon = CGI::param('telefon') || 'X';
my $fax = CGI::param('fax') || 'X';
my $email = CGI::param('mobil') || 'X';
######################
Skalar Zeitstempel
######################
my $Zeitstempel = time;
###############
Datenfilter
###############
$anrede =~ s/;//g;
$vorname =~ s/;//g;
$name =~ s/;//g;
$geboren =~ s/;//g;
$hausnummer =~ s/;//g;
$land =~ s/;//g;
$plz =~ s/;//g;
$ort =~ s/;//g;
$telefon =~ s/;//g;
$fax =~ s/;//g;
$email =~ s/;//g;
#################
Skalar Cookie
#################
my $cookie1;
$cookie1 = new CGI::Cookie(-name=>'eus-session',-value=>$Zeitstempel);
#############
HTML-Kopf
#############
print CGI->header(-type=> 'text/html', -cookie=>$cookie1);
print qq(<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">),"\n";
print qq(<html>),"\n";
print qq(<head>),"\n";
print qq(<title>Euro-Superconductors</title>),"\n";
print qq(<link rel="stylesheet" type="text/css" href="http://localhost/eus-home-de.css" media="screen, projection" >),"\n";
print qq(<meta http-equiv="Content-Language" content="de">),"\n";
print qq(<meta http-equiv="Content-Type" content="text/html; charset=utf-8">),"\n";
print qq(<meta name="generator" content="Texteditor/Gnome-Ubuntu">),"\n";
print qq(<meta name="title" content="Euro-Superconductors">),"\n";
print qq(<meta name="description" content="öffentliche Forschung und Handel mit Supraleiter, public research and trading with superconductors">),"\n";
print qq(<meta name="organization" content="Euro-Superconductors e. G.">),"\n";
print qq(<meta name="owner" content="Gary R.">),"\n";
print qq(<meta name="author" content="Gary R.">),"\n";
print qq(<meta name="publisher" content="www.euro-superconductors.com">),"\n";
print qq(<meta name="copyright" content="Euro-Superconductors / 2010">),"\n";
print qq(<meta name="abstract" content="Forschung, Entwicklung, Handel, Verkauf mit Supraleiter, science, development and trading with superconductors">),"\n";
print qq(<meta name="page-type" content="business">),"\n";
print qq(<meta name="distribution" content="global">),"\n";
print qq(<meta name="page-topic" content="Supraleiter, superconductors">),"\n";
print qq(<meta name="rating" content="general">),"\n";
print qq(<meta name="audience" content="Schüler, Studenten, Forscher, Wissenschaftler, pupils, students, explorers, scientists">),"\n";
print qq(<meta name="revisit" content="after 30 days">),"\n";
print qq(<meta name="robots" content="index, follow">),"\n";
print qq(<meta name="googlebot" content="noodp">),"\n";
print qq(<meta name="keywords" content="Supraleiter Informationen, informations about superconductors, Supraleiter kaufen, buy a superconductor, Supraleiter, superconductor, wo kann ich einen Supraleiter kaufen, where can I buy a superconductor, YBCO, ybco">),"\n";
print qq(</head>),"\n";
print qq(<body>),"\n";
print qq(<div class="hintergrund-oben">),"\n";
print qq(</div>),"\n";
print qq(<div class="hintergrund-oben-traverse">),"\n";
print qq(</div>),"\n";
print qq(<div class="hintergrund-unten">),"\n";
print qq(</div>),"\n";
print qq(<div class="hintergrund-links">),"\n";
print qq(</div>),"\n";
print qq(<div class="hintergrund-rechts">),"\n";
print qq(</div>),"\n";
print qq(<div class="ecke-oben-links">),"\n";
print qq(</div>),"\n";
print qq(<div class="ecke-oben-rechts">),"\n";
print qq(</div>),"\n";
print qq(<div class="ecke-unten-links">),"\n";
print qq(</div>),"\n";
print qq(<div class="ecke-unten-rechts">),"\n";
print qq(</div>),"\n";
print qq(<div class="haupt-banner">),"\n";
print qq(</div>),"\n";
print qq(<div class="inhalt-box-links">),"\n";
print qq( <ul class="liste-links">),"\n";
print qq( <li><a href="http://www.euro-superconductors.com/de-home.html">Willkommen</a></li>),"\n";
print qq( <li><a href="http://www.euro-superconductors.com/de-idee.html">Idee</a></li>),"\n";
print qq( <li><a href="http://www.euro-superconductors.com/de-forschung.html">Forschung</a></li>),"\n";
print qq( <li><a href="http://www.euro-superconductors.com/de-produkte.html">Produkte</a></li>),"\n";
print qq( <li><a href="http://www.euro-superconductors.com/de-sicherheit.html">Sicherheit</a></li>),"\n";
print qq( </ul>),"\n";
print qq(<a class="grafiklink" href="http://www.euro-superconductors.com/index.html"><img class="zeichen-unten-links" src="http://www.euro-superconductors.com/up-symbol.png" width="50" height="18" alt="^"></a>),"\n";
print qq(</div>),"\n";
print qq(<div class="schiebe-box-links">),"\n";
print qq(</div>),"\n";
print qq(<div class="inhalt-box-rechts">),"\n";
print qq( <ul class="liste-rechts">),"\n";
print qq( <li><a href="http://www.euro-superconductors.com/de-garantie.html">Garantie</a></li>),"\n";
print qq( <li><a href="http://www.euro-superconductors.com/de-kontakt.html">Kontakt</a></li>),"\n";
print qq( <li><a href="http://www.euro-superconductors.com/de-impressum.html">Impressum</a></li>),"\n";
print qq( <li><a href="http://www.euro-superconductors.com/de-quellen.html">Quellen</a></li>),"\n";
print qq( <li><a href="http://www.euro-superconductors.com/de-agb.html">AGB</a></li>),"\n";
print qq( </ul>),"\n";
print qq(<a class="grafiklink" href="http://www.euro-superconductors.com/index.html"><img class="zeichen-unten-rechts" src="http://www.euro-superconductors.com/up-symbol.png" width="50" height="18" alt="^"></a>),"\n";
print qq(</div>),"\n";
print qq(<div class="schiebe-box-rechts">),"\n";
print qq(</div>),"\n";
print qq(<div class="zentrum-box-mitte2">),"\n";
print qq(<h1>Produkte</h1>),"\n";
print qq(<p> </p>),"\n";
print qq(<ul class="zentrum-liste">),"\n";
print qq( <li><a class="littlelink" href="http://www.euro-superconductors.com/de-produkte.html">Supraleiter</a></li>),"\n";
print qq( <li><a class="littlelink" href="http://www.euro-superconductors.com/de-produkte-zu.html">Zubehör</a></li>),"\n";
print qq( <li><a class="littlelink" href="http://www.euro-superconductors.com/http://localhost/cgi-bin/de-produkte-be.pl">Bestellung</a></li>),"\n";
print qq(</ul>),"\n";
print qq(<div class="zentrum-viewer-be">),"\n";
print qq(<p class="minizeile"> </p>),"\n";
print qq(<form action="http://www.euro-superconductors.com/cgi-bin/warenkorb.pl" method="get">),"\n";
print qq(<label>),"\n";
print qq(<select class="mengenbreite" size="1" name="menge01">),"\n";
print qq(<option value="">---</option>),"\n";
print qq(<option value="1">1x</option>),"\n";
print qq(<option value="2">2x</option>),"\n";
print qq(<option value="3">3x</option>),"\n";
print qq(<option value="4">4x</option>),"\n";
print qq(<option value="5">5x</option>),"\n";
print qq(<option value="6">6x</option>),"\n";
print qq(<option value="7">7x</option>),"\n";
print qq(<option value="8">8x</option>),"\n";
print qq(<option value="9">9x</option>),"\n";
print qq(<option value="10">10x</option>),"\n";
print qq(</select>),"\n";
print qq(</label>),"\n";
print qq(<label>),"\n";
print qq(<select class="artikelbreite" size="1" name="artikel01">),"\n";
print qq(<option value="">---</option>),"\n";
print qq(<option value="10x5">YBCO 10x5 mm</option>),"\n";
print qq(<option value="10x5x2">YBCO 10x5x2 mm</option>),"\n";
print qq(<option value="20x5">YBCO 20x5 mm</option>),"\n";
print qq(<option value="20x5x6">YBCO 20x5x6 mm</option>),"\n";
print qq(<option value="30x5">YBCO 30x5 mm</option>),"\n";
print qq(<option value="30x5x8">YBCO 30x5x8 mm</option>),"\n";
print qq(<option value="40x5">YBCO 40x5 mm</option>),"\n";
print qq(<option value="40x5x10">YBCO 40x5x10 mm</option>),"\n";
print qq(<option value="50x8">YBCO 50x8 mm</option>),"\n";
print qq(<option value="50x8x14">YBCO 50x8x14 mm</option>),"\n";
print qq(<option value="60x8">YBCO 60x8 mm</option>),"\n";
print qq(<option value="60x8x14">YBCO 60x8x14 mm</option>),"\n";
print qq(<option value="70x8">YBCO 70x8 mm</option>),"\n";
print qq(<option value="70x8x14">YBCO 70x8x14 mm</option>),"\n";
print qq(<option value="80x10">YBCO 80x10 mm</option>),"\n";
print qq(<option value="80x10x22">YBCO 80x10x22 mm</option>),"\n";
print qq(<option value="90x10">YBCO 90x10 mm</option>),"\n";
print qq(<option value="90x10x22">YBCO 90x10x22 mm</option>),"\n";
print qq(<option value="100x10">YBCO 100x10 mm</option>),"\n";
print qq(<option value="100x10x22">YBCO 100x10x22 mm</option>),"\n";
print qq(</select>),"\n";
print qq(</label>),"\n";
print qq(<p class="minizeile"> </p>),"\n";
print qq(<label><input type="radio" name="task" value="plus-things"> Artikel hinzufügen!</label><br>),"\n";
print qq(<label><input type="radio" name="task" value="minus-things"> Artikel löschen!</label><br>),"\n";
print qq(<label><input type="radio" name="task" value="show-things"> Warenkorb ansehen!</label><br>),"\n";
print qq(<label><input type="radio" name="task" value="order-things"> Warenkorb bestellen!</label><br>),"\n";
print qq(<p class="minizeile"> </p>),"\n";
print qq(<input type="submit" value="Ausführen!" />),"\n";
print qq(</form>),"\n";
print qq(<p class="report">Ihre IP: ),$ENV {'REMOTE_ADDR'};
print qq(</p>),"\n";
print qq(<p class="report">Ihre Menge: ),$menge01;
print qq(</p>),"\n";
print qq(<p class="report">Ihr Artikel: ),$artikel01;
print qq(</p>),"\n";
print qq(<p class="report">Ihre gewählte Aufgabe: ),$task;
print qq(</p>),"\n";
print qq(<p class="report">Ihr Cookie-Inhalt: ),$Zeitstempel;
print qq(</p>),"\n";
print qq(</div>),"\n";
print qq(<p></p>),"\n";
print qq(<img class="kleine-ecke-oben-links" src="http://www.euro-superconductors.com/kleine-ecke-oben-links.png" width="8" height="8" alt="ecke-o-l">),"\n";
print qq(<img class="kleine-ecke-oben-rechts" src="http://www.euro-superconductors.com/kleine-ecke-oben-rechts.png" width="8" height="8" alt="ecke-o-r">),"\n";
print qq(<img class="kleine-ecke-unten-rechts" src="http://www.euro-superconductors.com/kleine-ecke-unten-rechts.png" width="8" height="8" alt="ecke-u-r">),"\n";
print qq(<img class="kleine-ecke-unten-links" src="http://www.euro-superconductors.com/kleine-ecke-unten-links.png" width="8" height="8" alt="ecke-o-l">),"\n";
print qq(</div>),"\n";
print qq(</body>),"\n";
print qq(</html>),"\n";
print qq(</html>),"\n";
Ja, wie gesagt - es geht - und keiner weiss warum >:-)
Gruß
Gary