Mobile app version of vmapp.org
Login or Join
Lee4591628

: Web Notification Design I am designing a website which my web user would interact on the site. Take FB poke function for example. There are two men A and B and they are both online. And

@Lee4591628

Posted in: #Notification #SocialNetworking

I am designing a website which my web user would interact on the site.

Take FB poke function for example. There are two men A and B and they are both online. And A poked B.

What I want to know is how to make B get an instant notification, knowing that A poked him just now ?

The way I thought is that make a javascript code to ajax the database for new notification every minutes. How could I reduce the amount of the times of query the data ?

Or is there any other way better?

10.01% popularity Vote Up Vote Down


Login to follow query

More posts by @Lee4591628

1 Comments

Sorted by latest first Latest Oldest Best

 

@Yeniel560

You can use WebSockets, a very good library for it is Socket.io. Then you can emit an event serverside and the client gets it immediately.

10% popularity Vote Up Vote Down


Back to top | Use Dark Theme