1.1. Atlas and AjaxAtlas builds on near-standard browser technologies, including Asynchronous JavaScript and XML. Ajax has itself generated quite a lot of buzz lately (see the "Preface" for some thoughts about that), since it can bring the functionality and UI of web applications closer to that of desktop applications. The main idea behind Ajax is to enable web pages to make HTTP requests in the background, or asynchronously, without reloading an entire page (or, in ASP.NET terms, without a roundtrip or a postback). Ajax also provides the means to build a more responsive UI by drawing on the power of JavaScript, the Document Object Model (DOM), and CSS, all of which most browsers support. JavaScript, for example, is used to display the information returned by an HTTP request, without a full page refresh. Google Suggest (http://www.google.com/webhp?complete=1&hl=en) shows how an Ajax-enabled page can suggest words as a user enters text (also known as autocompletion). Another Ajax-style application is the Microsoft Virtual Earth site (http://www.virtualearth.com), which you'll explore in Chapter 12. One goal of Atlas is to help you create these types of Ajax-enabled applications by programming the browser (client). To work with the client side of Ajax and Atlas, you need a good knowledge of the core Ajax technologies. You need to know JavaScript and the DOM, and you need to know about the XMLHttpRequest object, which handles the requests from the client to the server. (Additional knowledge of XML and XSLT is a plus, but is not mandatory; we don't use them much in this book.) While Chapter 2 covers the essentials of JavaScript, you'll learn about other Ajax technologies in greater detail in Chapter 3. To follow the example in this chapter (see "A First Atlas Example: Hello User") all you need is a basic understanding of the Ajax technologies, and we'll provide that as we go. Writing Ajax-based applications without a framework like Atlas is not necessarily easy, and you can find yourself writing the same code over and over to perform tasks such as displaying the data returned from a request to the server, binding controls to data, or working with web services. You can also find yourself writing code to work around differences in how browsers implement the DOM. One of the goals of Atlas is to reduce or even eliminate the need for writing such code and to deliver a client-side developer experience that matches the experience of ASP.NET 2.0 developers. A related goal is to bring some of the productivity advantages of object-oriented programming (OOP) and of a framework like .NET to JavaScript. Therefore, Atlas includes client-script libraries that give the JavaScript/DOM/CSS programmer the following:
|