How do pages like Yahoo Finance update page without plugins etc? (HTTP PUSH)

自古美人都是妖i 提交于 2020-01-04 06:09:18

问题


I am interested in HTTP PUSH technologies. I am interested in the technology behind pages like Yahoo Finance etc, which are able to update the page with data in real time.

When I checked the FF console, there are no periodic POSTs from the client which suggests that the client is not polling, rather it is having data PUSHed to it.

I then checked the page source - (AFAICT) they are NOT:

  • using a java applet
  • using a hidden iframe
  • using any custom client side JS library (like APE etc)

So HOW are the pages being updated in real time?.

Can anyone explain the technolgies used to put together such a page - a link to a simple demo would be most useful.


回答1:


The techniques for HTTP PUSH and the like are

  • Comet Technology
  • WebSockets
  • Java Applet / Flash WebSockets / SilverLight?
  • Server-sent Events and EventSource
  • HTTP server push

The Push technology article on wikipedia is a good read.

The Transports at socket.io should give you examples of how to implement these technologies.



来源:https://stackoverflow.com/questions/6759192/how-do-pages-like-yahoo-finance-update-page-without-plugins-etc-http-push

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!