remenissions Posted November 8, 2013 Share Posted November 8, 2013 To keep it simple I've searched all over google and these threads trying to find some tutorials on long polling. There's plenty of them too! The problem is I cannot seem to find any without frameworks like Jquery. Does anyone know of some guides or steps into turning a regular Ajax request into long polling without frameworks like Jquery? Quote Link to comment https://forums.phpfreaks.com/topic/283736-long-polling/ Share on other sites More sharing options...
kicken Posted November 8, 2013 Share Posted November 8, 2013 A long-poll request isn't any different from any other ajax request from the javascript side, the difference is on the server-side. What happens with a long-poll request is that your server-side will just wait until it has something to report rather than responding immediately (potentially with no data). Quote Link to comment https://forums.phpfreaks.com/topic/283736-long-polling/#findComment-1457612 Share on other sites More sharing options...
AaronClifford Posted November 10, 2013 Share Posted November 10, 2013 (edited) If you are looking to long poll, I'd consider taking a look at node.js it could be just what you are looking for. It's not reliant on JQuery. We are using it on a project that is in development at the moment to provide the user with live notifications; It's reduced load massively as we no longer need to keep checking for new data, we can just feed the user the new data as it becomes available. I've also just googled "node.js long polling" and found this tutorial on long polling in node.js that may be of use. Edited November 10, 2013 by AaronClifford Quote Link to comment https://forums.phpfreaks.com/topic/283736-long-polling/#findComment-1457779 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.