Mobile push notification

Is it possible to receive notifications on mobile devices whenever it is generated from a web server.

This thing can be achieved thanks to native apps for iPhone and Android. But my requirement is to achieve the same through a mobile site. You can also receive notifications even if the user has closed the web browser.

+5
source share
3 answers

It is possible, and you have 2 main ways to achieve this:

  • WebSockets (HTML 5 required)
  • Long HTTP polling

Both methods require some trick software, a good example is Socket.IO, which runs on the Node.JS platform.

- HTML 5 (, Chrome), .

HTTP - HTTP- , , . Node.JS , Socket.IO( Node.JS), . Socket.IO Websockets, , , .

, - Socket.IO . , . ASP.net, , .

+2

. , os.

+1

Server Sent Events (SSE). Android ICS SSE, . HTML5 (http://www.html5rocks.com/en/tutorials/eventsource/basics/) , (http://googlecodesamples.com/html5/sse/sse.html).

However, none of these solutions (websockets, SSE) would be useful if you want your application to work on older Android devices as well. These solutions are not useful if you want to receive push when your application does not start. The best solution is to create a kind of hybrid application, as richbayliss offers. You probably don't need a phone delay for this. You can fire an event using loadDataWithBaseURL WebView

0
source

All Articles