This is an archived snapshot of W3C's public bugzilla bug tracker, decommissioned in April 2019. Please see the home page for more details.
If my reading of Gecko source code is correct, the encoding of the document initiating a POST should be used when parsing the POST response if the HTTP header, BOM and meta prescan encoding sources fail for the POST response.
Henri, which code are you looking at here? The charset detection stuff in nsHTMLDocument uses all sorts of sources of information, including the previous document, parent document, etc, etc... is that what you're referring to?
I'm referring to http://mxr.mozilla.org/mozilla-central/source/content/html/document/src/nsHTMLDocument.cpp#844 I can't find any other occasion than a POST-based navigation where the encoding of the previous document is used. I also saw that same-origin frames inherit charset from the parent, but I wasn't prepared to file a spec bug about that, yet.
Ah, I didn't realize that was restricted to POST pages. For what it's worth, I suspect that there's a security issue there, and had been planning to go through this code carefully and rewrite it. See https://bugzilla.mozilla.org/show_bug.cgi?id=408457
According to my tests: http://www.hixie.ch/tests/adhoc/html/parsing/encoding/navigation/ ...neither WebKit or Opera do this. So I haven't done it in the spec either.
This bug predates the HTML Working Group Decision Policy. If you are satisfied with the resolution of this bug, please change the state of this bug to CLOSED. If you have additional information and would like the editor to reconsider, please reopen this bug. If you would like to escalate the issue to the full HTML Working Group, please add the TrackerRequest keyword to this bug, and suggest title and text for the tracker issue; or you may create a tracker issue yourself, if you are able to do so. For more details, see this document: http://dev.w3.org/html5/decision-policy/decision-policy.html This bug is now being moved to VERIFIED. Please respond within two weeks. If this bug is not closed, reopened or escalated within two weeks, it may be marked as NoReply and will no longer be considered a pending comment.