This question comes up to the following: write binary data using JavaScript on the server .
The problem with the simple use of Response.Writewriting a string is that the string contains a null character, which JavaScript recognizes as the end of the string.
The line I'm trying to write starts with the following (written here in character codes)
255 216 255 212 0 16 ...
JavaScript will only output the first 4 characters, because it recognizes the fifth as a line terminator. Is there any way around this?
I should note that I really need to write binary zero ... the output of this is pdf, so I cannot change the output format.
alumb source
share