13.07.2015 Views

Thesis full text PDF - Politecnico di Milano

Thesis full text PDF - Politecnico di Milano

Thesis full text PDF - Politecnico di Milano

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

2.2. Ajax Web Applications2.2.1. What is AjaxAjax has been minted as a term describing a Web development technique for creating richer anduser-friendlier Web applications. In this chapter, we will give you an overview of Ajax. One of thereasons Ajax has gained a great popularity is the XMLHttpRequest object and the way this objectmakes it possible for developers to asynchronously communicate with underlying servers andany business services used by Web applications. Popular sites such as Google GMail use Ajaxtechniques to provide users with rich interfaces that have increased the awareness of Ajax.Although the name Ajax is new, the technologies listed as the foundation of this technique(JavaScript, XMLHttpRequest, and the DOM) have been around for some time. In fact, the latestad<strong>di</strong>tion to this suite of technologies, the XMLHttpRequest object, was introduced by Microsoft in1999 with the release of Internet Explorer 5.0 and was implemented as an ActiveX component.The XMLHttpRequest object, although widely used, is not a standard; it could at best be called a“de facto” standard, since most modern browsers, inclu<strong>di</strong>ng Firefox, Internet Explorer, Opera,and Safari, support it. With the XMLHttpRequest object, developers can now send requests to theWeb server to retrieve specific data and use JavaScript to process the response. This ability tosend data between the client and the Web server reduces the bandwidth to a minimum andsaves time on the server since most of the processing to update the user interfaces takes placeon the client using JavaScript. The term AJAX refers to a loose grouping of technologies that areused to create dynamic, interactive web content. The term AJAX is an acronym for“Asynchronous JavaScript And XML”. It’s simply describing a technique that uses JavaScript torefresh a page’s contents from a web server without having to reload the entire page. This is<strong>di</strong>fferent from the tra<strong>di</strong>tional method of updating web pages, which requires the browser torefresh the entire page in order to <strong>di</strong>splay any changes to the content. The increasing availabilityof the XMLHttpRequest class in browsers, the coining of the catchy term AJAX, and the advent ofa number of high-profile examples such as Google Maps have allowed these kinds of highlyinteractive web applications to begin to gain traction in the development world. As the term AJAXhas become more widespread, its definition has expanded to refer more generally to browserbasedapplications that behave much more dynamically than old-school web apps. This new cropof AJAX web applications make more extensive use of interaction techniques like e<strong>di</strong>t-in-place<strong>text</strong>, drag and drop, and CSS animations or transitions to effect changes within the userinterface. AJAX can be a great solution for many web development projects, it can empower webapps to step up and take over a lot of the ground that previously was occupied almostexclusively by desktop applications. AJAX can improve the interactivity and speed of your app,ultimately making that application easier, more fun, and more intuitive to use. Often, AJAXapplications are described as being “like a desktop application in the browser.” AJAX web appsare significantly more responsive than tra<strong>di</strong>tional, old-fashioned web applications, and they canprovide levels of interactivity similar to those of desktop applications.8

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!