Can you write REALapplications with AJAX-.ppt
《Can you write REALapplications with AJAX-.ppt》由会员分享,可在线阅读,更多相关《Can you write REALapplications with AJAX-.ppt(55页珍藏版)》请在麦多课文档分享上搜索。
1、Can you write REAL applications with AJAX?,Phil Sarin Advanced UI Software April 15, 2009,Problem: Many web apps stink,Rich Internet Applications (RIAs),Easy deployment and maintenance “Desktop-like” interactivity Willing to sacrifice some “webness” (e.g., bookmarks),RIA Approaches,Browser plug-in F
2、lash/Flex, Java Swing, Silverlight Potentially greater interactivity, higher barrier to adoption Concerns about openness/control In browser, no plug-ins AJAX Lower barrier to adoption Cross-browser mayhem?,Questions for today,Can we approach AJAX development like “regular” GUI development? What are
3、the approaches/tradeoffs? Whats likely to become popular?,What is AJAX?,What is AJAX?,AJAX event handling,Some History,History: Hill Climbing,RIA: Which hill to climb?,Approaching RIAs from two hills,The HTTP Hill,The HTTP Hill,Static Pages,Server fetches and returns a web page Initially just text-b
4、ased With Mosaic, pictures too,The HTTP Hill,Dynamic Pages,Server-side CGI (mostly perl) Client-side Javascript,The HTTP Hill,“Frameworks”,MVC support (Struts 1 & 2, Rails, Django) Easier HTML generation (JSP, ERB, Freemarker, ) State/sessions Javascript libraries (Prototype, DOJO, jQuery),The HTTP
5、Hill,Pros/Cons (prior to AJAX),Very cheap for simple sites Reasonably flexible Mail clients! Web-friendly Bookmarkable Indexable Slow feedback Minimal interactivity Cross-browser mayhem,The Direct Manipulation Hill,The Direct Manipulation Hill,The Direct Manipulation Hill,GUI Toolkits,Common widget
6、set across applications Standalone or client-server,The Direct Manipulation Hill for Internet applications,Browser Plug-Ins,Flash, Java, Silverlight Took a long time to catch on,The Direct Manipulation Hill,Pros/Cons,Timely feedback Programming power (behaviors, constraints at least possible) Common
7、 widgets (consistency, usability) Flash/etc: more consistent runtime platform Flash/etc: needs a plug-in Cross-platform issues still exist Proprietary runtime platform,Where does AJAX fit in?,Where does AJAX fit in?,Both hills!,AJAX on the HTTP Hill,Tactical features Autocomplete Drag and drop AJAX-
8、aware code Raw Javascript/HTML/CSS Or with a library Okay for some applications Too limiting for RIAs Not the focus of this talk,Direct Manipulation AJAX,AJAX on the Direct Manipulation Hill,Separate development environment from runtime environment. Runtime environment: HTML/Javascript/CSS (AJAX) De
9、velopment environment: toolkit in another language Two approaches: thin and fat,Thin Client AJAX Approach,Example: Google Maps (pretend its a thin client app),A Grid of Images,Example: Google Maps,Sequence,Thin Client Pros and Cons,Simple programming: ignore the network All your code runs server-sid
10、e Programmers love it! Undo, behaviors, constraints: all possible! Scalability (server-side state, lots of requests) Slow feedback: network hop for each user action,Fat Client AJAX Approach,Example: Google Maps,Sequence,Wait a second,No AJAX calls involved in moving the map around! Mostly Javascript
11、. New image requests are synchronous Example AJAX call: adding an intermediate destination,Fat Client Pros and Cons,Scalable (client-side state, fewer HTTP calls) Fast feedback Undo, behaviors, constraints possible but undo more complex than on the desktop More complicated: network-aware, distribute
- 1.请仔细阅读文档,确保文档完整性,对于不预览、不比对内容而直接下载带来的问题本站不予受理。
- 2.下载的文档,不会出现我们的网址水印。
- 3、该文档所得收入(下载+内容+预览)归上传者、原创作者;如果您是本文档原作者,请点此认领!既往收益都归您。
下载文档到电脑,查找使用更方便
2000 积分 0人已下载
下载 | 加入VIP,交流精品资源 |
- 配套讲稿:
如PPT文件的首页显示word图标,表示该PPT已包含配套word讲稿。双击word图标可打开word文档。
- 特殊限制:
部分文档作品中含有的国旗、国徽等图片,仅作为作品整体效果示例展示,禁止商用。设计者仅对作品中独创性部分享有著作权。
- 关 键 词:
- CANYOUWRITEREALAPPLICATIONSWITHAJAXPPT
