Mastering Ajax, Part 1th: Introduction to Ajax

Source: Internet
Author: User
Tags object model

Understanding Ajax and how it works, an effective way to build a Web site

Introduction: Ajax consists of HTML, JavaScript technology, DHTML, and DOM, an excellent way to translate awkward Web interfaces into interactive Ajax applications. The author of this series is an Ajax expert who demonstrates how these technologies work together-from a general overview to a detailed discussion-to make efficient WEB development a reality. He also uncovered the mysteries of Ajax's core concepts, including XMLHttpRequest objects.

Five years ago, if you didn't know XML, you were an ugly duckling that nobody paid attention to. 18 months ago, Ruby became the center of attention, not knowing that Ruby programmers had to be on the bench. Today, if you want to keep up with the latest technology trends, your goal is Ajax.

But Ajax is not just a fashion, it's a powerful way to build a Web site, and it's not as difficult as learning a whole new language.

But before we go into the details of what Ajax is, let's take a few minutes to learn what Ajax does. Currently, there are two basic options for writing applications:

Desktop applications

WEB Application

The two are similar, and desktop applications are typically CD-media (sometimes downloaded from a Web site) and fully installed on your computer. Desktop applications may download updates using the Internet, but the code to run these applications is on the desktop computer. Web applications run on a Web server somewhere--not surprisingly, to access this application through a Web browser.

However, more important than where the running code of these applications is, is how the application works and how it interacts with it. Desktop applications are generally fast (running on your computer without waiting for an internet connection), with a beautiful user interface (usually related to the operating system) and extraordinary dynamics. You can click, select, enter, open menus and submenus, cruise around, and basically don't have to wait.

Web applications, on the other hand, are the latest trends that provide services that cannot be implemented on the desktop (such as Amazon.com and EBay). However, as the Web is strong, waiting waits, waits for the server to respond, waits for the screen to refresh, waits for the request to return and produces the new page.

It is obvious that this is said briefly, but the basic concept is this. As you may have guessed, Ajax is trying to build the functionality and interactivity of desktop applications, and the bridge between constantly updated Web applications. You can use the dynamic user interface and beautiful controls that are common in desktop applications, but in WEB applications.

What are you waiting for? Let's look at how Ajax translates a clumsy Web interface into an AJAX application that responds quickly.

Old technology, new skills

When it comes to Ajax, it actually involves a variety of technologies, and the flexibility to use it requires a deeper understanding of these different technologies (the first few articles in this series will discuss them separately). The good news is that you may already be familiar with most of these technologies, and better yet, that they are easy to learn and not as difficult as a complete programming language, such as Java or Ruby.

The following are the basic techniques used by AJAX applications:

HTML is used to build Web forms and determine which fields are used by other parts of the application.

JavaScript code is the core code for running Ajax applications, helping to improve communication with server applications.

DHTML or dynamic HTML, which is used to dynamically update forms. We will use Div, span, and other dynamic HTML elements to mark HTML.

The Document Object Model DOM is used (through JavaScript code) to handle the HTML structure and, in some cases, the XML returned by the server.

We are here to further analyze the responsibilities of these technologies. I'll delve into these technologies in a future article, as long as you are familiar with these components and technologies. The more familiar these codes are, the easier it is to move from a fragmented understanding of these technologies to a real grasp of those technologies (and also really open the door to WEB application development).

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.