ajax comet

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

有不少方法能够实现ajax和comet,这些底层实现有时叫作transports.ajax

 

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上下载图像。this

 

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属性。spa

 

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.orm

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

相关文章
相关标签/搜索