comet

Chrome's loading indicator keeps spinning during XMLHttpRequest

不打扰是莪最后的温柔 提交于 2019-11-27 10:31:22
问题 I'm writing an AJAX web app that uses Comet/Long Polling to keep the web page up to date, and I noticed in Chrome, it treats the page as if it's always loading (icon for the tab keeps spinning). I thought this was normal for Google Chrome + Ajax because even Google Wave had this behaviour. Well today I noticed that Google Wave no longer keeps the loading icon spinning, anyone know how they fixed this? Here's my ajax call code var xmlHttpReq = false; // Mozilla/Safari if (window.XMLHttpRequest

Stopping a iframe from loading a page using javascript

限于喜欢 提交于 2019-11-27 08:19:17
Is there a way in javascript of stopping an iframe in the middle of loading a page? The reason I need to do this is I have a background iframe streaming data from a web server (via a Comet style mechanism) and I need to be able to sever the connection at will. Any ideas welcome. For FireFox/Safari/Chrome you can use window.stop(): window.frames[0].stop() For IE, you can do the same thing with document.execCommand('Stop'): window.frames[0].document.execCommand('Stop') For a cross-browser solution you could use: if (navigator.appName == 'Microsoft Internet Explorer') { window.frames[0].document

Is there an alternative of ajax that does not require polling without server side modifications?

烂漫一生 提交于 2019-11-27 07:38:30
问题 I'm trying to create a small and basic "ajax" based multiplayer game. Coordinates of objects are being given by a PHP "handler". This handler.php file is being polled every 200MS, by using ajax. Since there is no need to poll when nothing happens, I wonder, is there something that could do the same thing without frequent polling? Eg. Comet, though I heard that you need to configure server side applications for Comet. It's a shared webserver, so I can't do that. Maybe prevent the handler.php

Simple comet example using php and jquery

白昼怎懂夜的黑 提交于 2019-11-27 06:41:07
Can anyone give me a good and simple example of the comet technique using PHP? I just need an example that uses a persistent HTTP connection or something similar. I don't want to use a polling technique, because I have something like that set up and not only is it difficult to work with and manage its a big hog of resources. Also I am using IIS7 not Apache. A good example would be really helpful so I can move on from this ugly polling technique. You should use polling, or use a web server which is specially conceived for long requests and COMET, with a good JS backend: function listen() { $

Comet & PHP: How to use Comet with a PHP Chat System?

给你一囗甜甜゛ 提交于 2019-11-27 05:41:55
问题 I have to build a simple chat system in PHP using Comet. I don't know what would be the best approach to this project. What is the best technique (cross-browser would be nice) to use, and how to implement it ? What libraries can I use that already have comet support. ( I don't want to use the Bayeux Protocol ) I already have a PHP backend running for the chat system, but I need some ideas for the interaction between client and server. Thank you all in advance. My regards. 回答1: You may want to

Javascript implementation of WS-I Reliable Secure Profile

徘徊边缘 提交于 2019-11-27 05:36:25
I'm using the .NET 4 server side implementation of Reliable Secure Profile for HTTP/S push and want to know if there is a JavaScript client available. No. There are several generic SOAP libraries to talk to web services but not one that is specifically geared towards WS-I or the RSP definition. It might make for a good open source project though. Please add info here if you start it up, others might like it :) 来源: https://stackoverflow.com/questions/5724558/javascript-implementation-of-ws-i-reliable-secure-profile

Server Scalability - HTML 5 websockets vs Comet

自作多情 提交于 2019-11-27 05:05:34
问题 Many Comet implementations like Caplin provide server scalable solutions. Following is one of the statistics from Caplin site: A single instance of Caplin liberator can support up to 100,000 clients each receiving 1 message per second with an average latency of less than 7ms. How does this to compare to HTML5 websockets on any webserver? Can anyone point me to any HTML 5 websockets statistics? 回答1: Disclosure - I work for Caplin. There is a bit of misinformation on this page so I'd like to

What does it call in GWT to make 2 UI consistent?

試著忘記壹切 提交于 2019-11-27 04:40:37
问题 I saw a video of Google I/O and found an example of GWT UI being very consistent between clients. Which you can save, add, drag and drop in almost real time between clients. I currently don't understand the basic of this (In GWT, i think it implement Comet), so is there anyone can give me a term or definition for this? so I can get it on Google for more information? Thank you very much 回答1: OK, I think what you are looking for is known under the names Comet, Server Push, Reverse Ajax (to name

solution for COMET and PHP

六眼飞鱼酱① 提交于 2019-11-27 04:27:07
问题 Is there a real solution for COMET AND PHP combination? Basically, I've come to a point that I need to update a user home page periodically whenever there is new data in the database. As far as I understand, I need to open a persistent connection between my server and my clients browsers to update the contents of their home page as soon as new info. available without dedicating a lot of resources but I had no luck finding anything clear about this issue. I read many articles suggests that PHP