Hacker News new | ask | show | jobs
by chris_wot 5157 days ago
Interesting. I created a javascript module that emulates an ActiveX control. It needs to parse binary data sent from the web server.

I actually got it working in Opera, Firefox, Chrome and Safari via JDataView, which parses the binary data via a string. However, it doesn't work in Internet Explorer because IE will not read past a zero byte (null character). The data is actually there, you can see it in the debugger, but it won't let you get to it. This behaviour isn't mandated by the ECMA spec, and all other browsers handle it fine.

You can do a massive VBScript hack, which may stop working at any time. I decided that I'd not support Internet Explorer because I can't use it - even in IE9 and 10. Call me lazy if you like - I don't care. I'm not hacking up VBscript to get around a crazy Microsoft Javascript string processing decision!

1 comments

Holy edge case, batman!

I get what you're saying, but no-one in this discussion is trying to emulate ActiveX controls, just make a web site. And recent versions of IE really aren't that bad for it.

Actually, that was my use case. Quite a few people are using jdataview for other interesting applications. I was merely explaining what I was trying to do, sure it's an edge case but it's actually an example of where Microsoft don't follow the ECMA standard.

Not sure why the post was voted down. I think the fact that Microsoft aren't following the ECMA standard for string processing is actually a fairly egregious example of why it's just not worthwhile in many instances to develop for IE.