Open Bug 298680 Opened 16 years ago Updated 2 years ago

FireFox not sending any user selected character Encoding to server during submit or during any request

Categories

(Core :: DOM: Core & HTML, defect)

x86
Windows XP
defect
Not set
major

Tracking

()

UNCONFIRMED

People

(Reporter: ilanjava, Unassigned)

Details

User-Agent:       Mozilla/5.0 (Windows; U; Windows NT 5.1; en-GB; rv:1.7.8) Gecko/20050511 Firefox/1.0.4 StumbleUpon/1.9993
Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-GB; rv:1.7.8) Gecko/20050511 Firefox/1.0.4 StumbleUpon/1.9993

When communication from Client (browser) to Server takes place, FireFox not
sending any user selected character Encoding to server during submit or during
any request to the server.

When we make request to any server / submit the webpage, and if user encoding is
set to UTF-8 or any encoding (by selecting thru View > Character Encoding).
Firefox doesn’t send any of the user selected encoding.

Due to this when we submit the form with UTF-8 or ISO-8859-2 character, there is
no way to know in the server side, received data is encoded in which character
set encoding. 

Http 1.1 RFC specifies: Http header "Content-Type" user to identify the
transmitted data. 

During submitting of the form Firefox doesn’t send "Content-Type" HTTP header.
Due to this Java javax.servlet.ServletRequest.getCharacterEncoding() method
returns NULL.

We can confirm this by using the tool 'Live HttpHeaders'. Only following headers
are send to server during particular request. They are

GET http://edit.europe.yahoo.com
Host: edit.europe.yahoo.com
User-Agent: 
Accept:
text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Accept-Encoding: gzip,deflate
Accept-Charset: ISO-8859-1,utf-8;q=0.7,*;q=0.7
Keep-Alive: 300
Proxy-Connection: keep-alive
Referer: http://login.europe.yahoo.com/
Cookie: 
Cache-Control: max-age=0


Reproducible: Always

Steps to Reproduce:
1.Set character Encoding to UTF-8 or ISO-8859-2 by (View > 'Character Encoding'
option)
2. Submit the form 
3. View the submitted HttpHeaders by using 'Live HttpHeaders'

Actual Results:  
GET http://edit.europe.yahoo.com
Host: edit.europe.yahoo.com
User-Agent: 
Accept:
text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Accept-Encoding: gzip,deflate
Accept-Charset: ISO-8859-1,utf-8;q=0.7,*;q=0.7
Keep-Alive: 300
Proxy-Connection: keep-alive
Referer: http://login.europe.yahoo.com/
Cookie: 
Cache-Control: max-age=0


Expected Results:  
GET http://edit.europe.yahoo.com
Host: edit.europe.yahoo.com
User-Agent: 
Accept:
text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Accept-Encoding: gzip,deflate
Accept-Charset: ISO-8859-1,utf-8;q=0.7,*;q=0.7
Keep-Alive: 300
Proxy-Connection: keep-alive
Referer: http://login.europe.yahoo.com/
Cookie: 
Cache-Control: max-age=0

In addition to this we should get 
'Content-Type' header.

Can i set this to Major or this not bug at all ?? :)
Related to Core bug 232191?
I really dont know is this is related to that bug 232191. 

Is there is any way we can get the information from browser, regarding which
character encoding was used during submit of the page?

I will appreciate if you are able to provide me with some info or point me to
some resource where i can get more information.

-> Core
Assignee: nobody → form-submission
Component: General → HTML: Form Submission
Product: Firefox → Core
QA Contact: general → ian
Assignee: form-submission → nobody
QA Contact: ian → form-submission
Component: HTML: Form Submission → DOM: Core & HTML
You need to log in before you can comment on or make changes to this bug.