ImageVerifierCode 换一换
格式:DOC , 页数:9 ,大小:137KB ,
资源ID:13159947      下载积分:3 金币
快捷下载
登录下载
邮箱/手机:
温馨提示:
快捷下载时,用户名和密码都是您填写的邮箱或者手机号,方便查询和重复下载(系统自动生成)。 如填写123,账号就是123,密码也是123。
特别说明:
请自助下载,系统不会自动发送文件的哦; 如果您已付费,想二次下载,请登录后访问:我的下载记录
支付方式: 支付宝    微信支付   
验证码:   换一换

加入VIP,免费下载
 

温馨提示:由于个人手机设置不同,如果发现不能下载,请复制以下地址【https://www.bdocx.com/down/13159947.html】到电脑端继续下载(重复下载不扣费)。

已注册用户请登录:
账号:
密码:
验证码:   换一换
  忘记密码?
三方登录: 微信登录   QQ登录  

下载须知

1: 本站所有资源如无特殊说明,都需要本地电脑安装OFFICE2007和PDF阅读器。
2: 试题试卷类文档,如果标题没有明确说明有答案则都视为没有答案,请知晓。
3: 文件的所有权益归上传用户所有。
4. 未经权益所有人同意不得将文件中的内容挪作商业或盈利用途。
5. 本站仅提供交流平台,并不能对任何下载内容负责。
6. 下载文件中如有侵权或不适当内容,请与我们联系,我们立即纠正。
7. 本站不保证下载资源的准确性、安全性和完整性, 同时也不承担用户因使用这些下载资源对自己和他人造成任何形式的伤害或损失。

版权提示 | 免责声明

本文(ajax英文文献Word文档下载推荐.doc)为本站会员(b****1)主动上传,冰豆网仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对上载内容本身不做任何修改或编辑。 若此文所含内容侵犯了您的版权或隐私,请立即通知冰豆网(发送邮件至service@bdocx.com或直接QQ联系客服),我们立即给予删除!

ajax英文文献Word文档下载推荐.doc

1、 XMLHttpRequest; Web Applications I. INTRODUCTION Ajax is shorthand for Asynchronous JavaScript and XML (and DHTML, and so on). The phrase was coined by Jesse James Garrett of Adaptive Path and is, according to Jesse, not meant to be an acronym. However, Ajax is far more than just a fad; its a power

2、ful approach to building Web sites and its not nearly as hard to learn as an entire new language. Figure 1. The traditional model for web applications (left) compared to the Ajax model (right)Ajax isnt a technology. Its really several technologies, each flourishing in its own right, coming together

3、in powerful new ways. Ajax incorporates:. standards-based presentation using XHTML and CSS;. dynamic display and interaction using the Document Object Model;. data interchange and manipulation using XML and XSLT;. asynchronous data retrieval using XMLHttpRequest;. JavaScript binding everything toget

4、her. The classic web application model works like this:Most user actions in the interface trigger an HTTP request back to a web server. The server does some processing retrieving data, crunching numbers, talking to various legacy systems and then returns an HTML page to the client. Its a model adapt

5、ed from the Webs original use as a hypertext medium, but as fans of the Elements of User Experience know, what makes the Web good for hypertext doesnt necessarily make it good for software applications. This approach makes a lot of technical sense, but it doesnt make for a great user experience. Whi

6、le the server is doing its thing, whats the user doing? Thats right, waiting. And at every step in a task, the user waits some more. Obviously, we wouldnt make users wait around in designing the Web from scratch for applications. Once an interface is loaded, why should the user interaction come to a

7、 halt every time the application needs something from the server? In fact, why should the user see the application go to the server at all?II. MAKE ASYNCHRONOUS REQUESTS WITH JAVASCRIPT AND AJAX Most Web applications use a request/response model that gets an entire HTML page from the server. The res

8、ult is a back-and-forth that usually involves clicking a button, waiting for the server, clicking another button, and then waiting some more. With Ajax and the XMLHttpRequest object, we can use a request/response model that never leaves users waiting for a server to respond. A. Introducing XMLHttpRe

9、quest XMLHttpRequest has actually been around in several browsers for quite a while, which is the key to Web 2.0, Ajax, and pretty much everything. To give a really quick overview, these are just a few of the methods and properties will be used on this object:. open (): Sets up a new request to a se

10、rver. . send (): Sends a request to a server. . abort (): Bails out of the current request. . readyState: Provides the current HTML ready state. . responseText: The text that the server sends back to respond to a request. Each of these methods and properties relate to sending a request and dealing w

11、ith a response. In fact, if we saw every method and property of XMLHttpRequest, they would all relate to that very simple request/response model. So clearly, we wont learn about an amazing new GUI object or some sort of super-secret approach to creating user interaction; programmers will work with s

12、imple requests and simple responses. It might not sound exciting, but careful use of this one object can totally change our applications. First, we need to create a new variable and assign it to an instance of the XMLHttpRequest object. Thats pretty simple in JavaScript, just use the new keyword wit

13、h the object name, like in Fig.2. Figure 2. Create a new XMLHttpRequest objectIn real life, things can go wrong and this code doesnt provide any error-handling. A slightly better approach is to create this object and have it gracefully fail if something goes wrong. For example, many older browsers (

14、believe it or not, people are still using old versions of Netscape Navigator) dont support XMLHttpRequest and Web applications need to let those users know that something has gone wrong. Fig.3 shows how to create this object so if something fails, it throws out a JavaScript alert. Figure 3. Create XMLHttpRequest with some error-handling abilitiesIt turns out that Microsoft supports Ajax, but calls its version of XMLHttpRequest something di

copyright@ 2008-2022 冰豆网网站版权所有

经营许可证编号:鄂ICP备2022015515号-1