Dev.Opera - Follow the standards, break the rulesDev.Opera - Follow the standards, break the rules

Login

Lost password?

Forums » General Discussions

General DevOpera discussion group

Note: You need to login to post in the forums. if you don't have an account you first need to sign up.

By ChrisNelson anchor Friday, 21. March 2008, 19:21:01

avatar

How can I access binary data from JavaScript in Opera?

Following techniques described at http://tinyurl.com/25762x , I can retrieve a binary file in Firefox and retrieve it from the responseText field of the request response object.

In IE, the responseText field is empty and the data I'm looking for is in the responseStream field. When running the Microsoft Script Editor, I can view this property and it shows as an array of BYTE with the correct length. However, I can't access it from JavaScript which doesn't have a BYTE data type.

In Opera, the responseText field has a length of about 18k when retrieving a 50k file. I wonder if Opera isn't interpreting the raw data as some multi-byte character set or finding the first NUL and thinking that's the end.

Any guidance in accessing binary files on the server in Opera would be very much appreciated.

By lnmx anchor Saturday, 22. March 2008, 07:55:12

avatarprobably u getting compressed content

By ChrisNelson anchor Tuesday, 25. March 2008, 13:58:35

avatar

Originally posted by lnmx:

probably u getting compressed content


No, just raw binary data that I want the browser to keep its mitts off of.

Moderators: jax | malware | mcx | operadev