Refactor: use jquery.websocket.js file