CGI: How do I do this?
Doru-Catalin Togea
doru-cat at ifi.uio.no
Fri Oct 25 08:08:39 EDT 2002
Hi again!
I found several Perl examples of what I am trying to do. I'm sure the same
can be done in Python, but how?
#!/usr/bin/perl -wT
use strict;
use CGI qw(:standard);
use CGI::Carp qw(fatalsToBrowser);
print header(), start_html();
my @fields = CGI::param(); <-- how do I do this
in Python?
print "<pre><br>\n";
foreach my $k (@fields) {
my $v = param($k);
print "<b>$k</b> -> \"$v\"<br>";
}
print "</pre>\n";
print end_html();
<<<< ================================== >>>>
<< We are what we repeatedly do. >>
<< Excellence, therefore, is not an act >>
<< but a habit. >>
<<<< ================================== >>>>
More information about the Python-list
mailing list