摘要
传统的Web应用解决方案将所有的操作集成在服务器端进行,客户端所做的工作只是简单的显示网页。Ajax的出现改变了传统Web开发的模式,通过异步方式的数据传输实现Web服务的有效性和独立性,将之前的单击显示页面式的体验变成具有交互性、灵活性的桌面应用程序体验。基于Ajax技术的Web程序开发和应用不仅对浏览器兼容性差,而且采用传统的XML进行数据传输。XML数据格式在使用的过程中不仅会带来很多数据冗余,而且还不容易对其解析。将XML和JSON进行对比和分析,最终以JSON作为Ajax通信中的数据传递格式,并用jQuery中的方法来解析JSON数据与封装Ajax异步请求。jQuery是一个优秀、灵活多变的JavaScript框架,可以兼容CSS3和各种主流的浏览器,其模块化的开发方式可以让开发者按需加载资源。在分析了传统的Web开发模式存在的问题后,提出了基于jQuery框架的Ajax异步请求,实现Web快速便捷开发与更优化的用户体验。
Traditional Web application solutions integrate all operations performed on the server side, while tile workdone by the client simply displays the webpage. Ajax has changed the traditional Web development model. It realizes theeffectiveness and independence of Web services through Asynchronous data transfer, making the transition from theprevious experience of Clicking to show the style to the experience of interactive, flexible desktop application. Webapplication development based on Ajax technology not only is poor for browser compatibility but also uses the traditionalXML data format. This kind of data format will not only generate large amounts of data redundancy, but also exist theissues of Complex data analysis. By comparing XML with JSON, this paper chooses JSON as the data transmissionformat in Ajax, and uses jQuery to parse JSON data and package Ajax asynchronous request. jQuery is an excellent,flexible javaseript framework and compatible with CSS3 and various browsers. Its modular development approach allowsdevelopers to load resources on demand. After analyzing the traditional problems of Web development model, this articleproposes Ajax asynchronous request based on jQuery framework to achieve quick and easy Web development and moreoptimal user experience.
出处
《沈阳师范大学学报(自然科学版)》
CAS
2015年第1期96-99,共4页
Journal of Shenyang Normal University:Natural Science Edition
基金
辽宁省高等学校本科专业设置预测系统研究项目(辽教函[1008]225号)