Closed Bug 367026 Opened 18 years ago Closed 18 years ago

HZ-GB-2312 character encoding output gets re-arranged

Categories

(Core :: Internationalization, defect)

x86
Windows 2000
defect
Not set
normal

Tracking

()

RESOLVED FIXED

People

(Reporter: taras.di, Assigned: smontagu)

References

Details

Attachments

(2 files)

User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.8.0.9) Gecko/20061206 Firefox/1.5.0.9 Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.8.0.9) Gecko/20061206 Firefox/1.5.0.9 Submitting the 'yi' Chinese character with the form's accept-charset="HZ-GB-2312" results in the browser posting a byte stream that is mixed up. The character in question is at unicode code point 4E00. Make sure that your form attributes are set as follows: method="post" enctype="multipart/form-data" accept-charset="HZ-GB-2312" Copy and paste the 'yi' character from MS Word for example (or a suitable website such as http://people.w3.org/rishida/scripts/uniview/), set up Ethereal to capture the outgoing request. Post the request. You will see that the order in which the bytes should be posted, 7E 7B 52 3B 7E 7D (http://en.wikipedia.org/wiki/HZ_%28character_encoding%29) does not match the order in which they're posted (see the attached screenshot of the Ethereal output). This incorrect order can also be seen by echoing the POST variable to the browser (by using PHP for instance). The URL I used for testing was at http://www.easyload.com.au/taras/form.php Reproducible: Always Steps to Reproduce: 1.See above 2. 3. Actual Results: Output of bytes is in wrong order 7E 7B 52 3B 7E Expected Results: Expect bytes to be in the following order:
Attached image Ethereal output (deleted) —
Assignee: nobody → smontagu
Status: UNCONFIRMED → NEW
Component: General → Internationalization
Ever confirmed: true
Product: Firefox → Core
QA Contact: general → i18n
Version: unspecified → Trunk
This is a bug in the HZToUnicode converter. Taking.
Status: NEW → ASSIGNED
UnicodeToHZ, that is.
Attached patch Patch (deleted) — Splinter Review
Attachment #251628 - Flags: superreview?(roc)
Attachment #251628 - Flags: review?(jshin1987)
Attachment #251628 - Flags: superreview?(roc) → superreview+
Comment on attachment 251628 [details] [diff] [review] Patch r=jshin sorry for the delay
Attachment #251628 - Flags: review?(jshin1987) → review+
Checked in
Status: ASSIGNED → RESOLVED
Closed: 18 years ago
Resolution: --- → FIXED
Flags: in-testsuite+
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: