gimite / web-socket-js

HTML5 Web Socket implementation powered by Flash
BSD 3-Clause "New" or "Revised" License
2.74k stars 490 forks source link

Safari <= 5.1 Fix #139

Open Bizarrus opened 10 years ago

Bizarrus commented 10 years ago

Override Safari's (old) WebSocket and force to flash

gimite commented 10 years ago

What's wrong with Safari 5.1's WebSocket?

Bizarrus commented 10 years ago

Sorry, i mean only Safari 5.1.

Safari has problems with Handshaking. I have added these lines to force to the Flash-Fallback. Only set "WEB_SOCKET_FORCE_FLASH" will not working.

gimite commented 10 years ago

What kind of handshaking problem does it have? Do you know why WEB_SOCKET_FORCE_FLASH doesn't hep? Note that you need to set the variable before loading web-socket-js. e.g.

<script type="text/javascript">
  WEB_SOCKET_FORCE_FLASH = true;
</script>
<script type="text/javascript" src="web_socket.js"></script>
<script type="text/javascript">
  ....
</script>