NetTalk Central

NetTalk Web Server => Web Server - Ask For Help => Topic started by: markster on December 03, 2014, 08:28:52 AM

Title: Push notification
Post by: markster on December 03, 2014, 08:28:52 AM
Is there any relatively simple way to push a notification from the server to a browser? In my app, a user can post an invoice to recipient via WebServer processing. I need to figure out a way to notify the receipient that a new invoice has been created and payment is due (ie. a POS situation) so that they can make the payment then and there.

Regards,

Mark
Title: Re: Push notification
Post by: Bruce on December 03, 2014, 08:39:36 AM
Hi Mark,

The short answer is no - there is no open connection between the server and the browser, so there's no way to push from the server to the browser.

However, Dries is doing a session next week Friday (12th dec 2014) on ClarionLive on using WebSockets - and that does open a connection, so using that approach is probably is possible. So make sure you catch that.

Cheers
Bruce
Title: Re: Push notification
Post by: mriffey on May 06, 2015, 04:09:38 PM
Something else that will do this and is "more modern" than websockets is Server Sent Events. See http://html5rocks.com/en/tutorials/eventsource/basics/
Title: Re: Push notification
Post by: peterH on May 07, 2015, 01:38:40 AM
Hi Mark,

Very interesting reading, thanks for the link.

Peter
Title: Re: Push notification
Post by: Bruce on May 07, 2015, 06:42:30 AM
>> Something else that will do this and is "more modern" than websockets is Server Sent Events.

I investigated these some time ago, but unfortunately they're completely not supported on IE so they're not a generally useful solution. WebSockets are more generally supported, and you can implement the same functionality (and more) over WebSockets so I determined that WebSockets would be the better option in the longer term.

WebSocket support is currently on the Roadmap for NetTalk 9.

cheers
Bruce
Title: Re: Push notification
Post by: mriffey on May 07, 2015, 04:09:29 PM
Thats good news. Thanks:)