I have a GoDaddy Linux hosting , any idea how do I run a websocket server for my HTML5 web app ? Any other recommendation ?
I know VPS can do it, but it is costly , any PaaS solution ?
If you have a shared hosting plan, you will very likely not be able to access sockets, thus making it impossible to use the WebSocket API.
You're going to need a virtual private server for this one.
If you got that set up you can take a look at socket.io and node.js which does exactly what you're looking for. There are a couple of examples of how to set it up on their websites plus you can take a look at this blog post which has some examples on how to set up node.js and socket.io with html5's canvas and websockets to have some realtime drawing going on.
Edit: Theres a second option of running a php based socket server, although not as good as the option above, but it can probably(?) be done without vps.
PHP has seme basic functions to create a socket server that are listed here. There are a couple of examples of how to set it up such this. And theres also this stackoverflow answer here that lists a couple of google code projects that does exactly what you need such as this.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With