码迷,mamicode.com
首页 > Web开发 > 详细

ajax comet

时间:2015-03-18 15:47:06      阅读:140      评论:0      收藏:0      [点我收藏+]

标签:

There are a number of ways to implement Ajax and Comet, and these underlying implementations
are sometimes known as transports.

有很多方法可以实现ajax和comet,这些底层实现有时叫做transports.

 

The <img> element, for example,
has a src property. When a script sets this property to a URL, an HTTP GET request
is initiated to download an image from that URL.

例如,<img>元素有一个src属性。当脚本设置它的属性为一个URL时,一个HTTP GET请求被创建,来从这个URL上下载图像。

 

A script can therefore pass information
to a web server by encoding that information into the query-string portion of the
URL of an image and setting the src property of an <img> element.

脚本可以向服务器传送信息,通过把那些信息编码成图像URL的查询字符串的一部分,和设置<img>元素的src属性。

 

The web server must
actually return some image as the result of this request, but it can be invisible: a transparent
1-pixel-by-1-pixel image, for instance.

服务器必须返回一些图像,作为这个请求的结果,但是它可以不可见:例如一张透明图片。

 

ajax comet

标签:

原文地址:http://www.cnblogs.com/sunhe/p/4347151.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!