Closed Bug 142272 Opened 23 years ago Closed 23 years ago

"document.writing" iso-8859-2 characters using javascript makes the text unreadable

Categories

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

x86
Linux
defect
Not set
normal

Tracking

()

RESOLVED FIXED

People

(Reporter: migli, Assigned: jst)

References

()

Details

From Bugzilla Helper: User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.0rc1) Gecko/20020417 BuildID: 2002041717 When I put the content of a new page into a variable, and then i "document.write" the variable into a window, all characters, that are specific for iso-8859-2 encoding are displayed wrong. Reproducible: Always Steps to Reproduce: 1.Put the whole page into a variable, use some unusual encoding and characters 2.document.write the variable into a window Expected Results: It should display the characters correctly. You can have look at http://www.volny.cz/migli/charset_problem.html
Is the frame that you are calling document.write() from in ISO-8859-2? As far as I can tell, it does not indicate a charset, and is thus treated as ISO-8859-1 (it contains only valid ISO-8859-1 chars).
Summary: "document.writing" iso-8859-2 characters using javascript makes the text unreadable → "document.writing" iso-8859-2 characters using javascript makes the text unreadable
Well, it seems I found a reason, why the text looks odd. Please, have a look at the URL http://www.volny.cz/migli/charset_problem.html and click on the link in the bottom frame. Now the characters look odd. Then, set "View->Character coding->unicode"; the characters look fine. It seems, that the javascript engine reads the characters in iso8859-2 encoding, transforms it into unicode and prints them. I am not sure, if this is a correct behaviour, and if it is, is there any way how to make javascript print characters in iso8859-2 encoding using document.write?
Solved in RC2, great work people!!! I really love this browser:-))))))
Status: UNCONFIRMED → RESOLVED
Closed: 23 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.