Closed
Bug 147904
Opened 22 years ago
Closed 22 years ago
<form enctype=text/plain>
Categories
(Core :: DOM: Core & HTML, enhancement)
Core
DOM: Core & HTML
Tracking
()
VERIFIED
FIXED
People
(Reporter: douglas, Assigned: john)
References
(Depends on 1 open bug, )
Details
(Keywords: compat)
A request is made for text/plain POST data. Instead, it comes out urlencoded.
<html><body>
This form specifies enctype=text/plain.
<form id="form1" enctype="text/plain" method="post"
action="http://www.netscape.com">
<input type="submit" name="Submit" value="Submit">
</form>
Unfortunately, the POST data is urlencoded.
<pre>
<form id="form1" enctype="text/plain" method="post"
action="http://www.netscape.com">
POST / HTTP/1.1
Host: www.netscape.com
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.0rc3)
Gecko/20020523
Accept:
text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,video/x-mng,image/png,image/jpeg,image/gif;q=0.2,text/css,*/*;q=0.1
Accept-Language: en-us, en;q=0.50
Accept-Encoding: gzip, deflate, compress;q=0.9
Accept-Charset: ISO-8859-1, utf-8;q=0.66, *;q=0.66
Keep-Alive: 300
Cookie: UIDC=20011214170359:209.220.10.66:4054; NSCPHPAD1=set; ptfc=yfki;
dcisid=2164056609.1022082227.2658781
Content-Type: application/x-www-form-urlencoded
Content-Length: 13
Connection: keep-alive
Submit=Submit
</pre>
</body></html>
Comment 1•22 years ago
|
||
See http://www.w3.org/TR/html401/interact/forms.html#form-content-type
Basically, that value's behavior is completely undefined -- it is treated just
like an illegal value. The standard behavior for illegal values is to fall
back on the default value, which is application/x-www-form-urlencoded.
What exactly do you expect the results of an enctype="text/plain" submission to
be?
Reporter | ||
Comment 2•22 years ago
|
||
It should encode the POST data as literal plain text, like IE does.
Comment 3•22 years ago
|
||
So just like a url-encoded post (name/value pairs separated by equals signs and
ampersands) except without the URL encoding? What happens if a name contains
an equals sign or a value contains an ampersand?
Reporter | ||
Comment 4•22 years ago
|
||
What happens if a name contains an equals sign or a value contains an
ampersand? That's what you get. If that's a problem for an application, they
should to validation prior to submission.
Comment 5•22 years ago
|
||
OK. So it's an enhancement request that we implement this IE extension.....
Severity: major → enhancement
Status: UNCONFIRMED → NEW
Ever confirmed: true
Keywords: compat
OS: Windows 2000 → All
Hardware: PC → All
Assignee | ||
Comment 6•22 years ago
|
||
This is done with the mailto form submit patch. text/plain is the enctype used
for that, and I made it possible to submit with POST to a server this way.
Assignee: alexsavulov → jkeiser
Depends on: 61893
Assignee | ||
Comment 7•22 years ago
|
||
This is done with the mailto form submit patch. text/plain is the enctype used
for that, and I made it possible to submit with POST to a server this way.
Status: NEW → ASSIGNED
Assignee | ||
Comment 9•22 years ago
|
||
Marking fixed :)
Status: ASSIGNED → RESOLVED
Closed: 22 years ago
Resolution: --- → FIXED
Updated•6 years ago
|
Component: HTML: Form Submission → DOM: Core & HTML
You need to log in
before you can comment on or make changes to this bug.
Description
•