Subject: | enctype : new default cannot be overridden |
<pre>
Operating system Linux
Kernel version 2.4.27-3trsmp
Machine Type i686
Apache version 1.3.33 (Unix)
PERL version 5.8.3
Following script :
#! /usr/bin/perl
use CGI;
use strict;
my $q = new CGI;
print $q->header;
print $q->start_html(-title=>'macCopy');
print $q->start_form(-enctype=>&CGI::URL_ENCODED,
-action=>"myAction.pl");
print $q->endform;
print $q->end_html;
Creates following output:
<!DOCTYPE html
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="en-US" xml:lang="en-US">
<head>
<title>macCopy</title>
<meta http-equiv="Content-Type" content="text/html;
charset=iso-8859-1" />
</head>
<body>
<form method="post" action="myAction.pl" enctype="multipart/form-data"
enctype="application/x-www-form-urlencoded">
</form>
</body>
</html>
<a href="http://perlmonks.com/?node_id=442565">More discussion</a>
</pre>