13.09.2016 Views

PHP and MySQL Web Development 4th Ed-tqw-_darksiderg

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

34<br />

Building <strong>Web</strong> 2.0 Applications<br />

with Ajax<br />

THE WORLD WIDE WEB BEGAN AS A SERIES of static pages containing text <strong>and</strong> links to<br />

image, audio, <strong>and</strong> video files. For the most part, the <strong>Web</strong> still exists in this state, although<br />

many of these pages filled with text <strong>and</strong> multimedia are dynamically generated through<br />

server-side scripting; this is what you have created through the applications in this book.<br />

But the advent of <strong>Web</strong> 2.0 has led developers to attempt to find new methods of user<br />

interaction with the web servers <strong>and</strong> databases that store the information we desire. One<br />

increasingly popular method of interaction is through the use of Ajax (Asynchronous<br />

JavaScript <strong>and</strong> XML) programming to enhance interactivity while reducing the time<br />

spent retrieving static elements.<br />

Note<br />

To better underst<strong>and</strong> the concept of <strong>Web</strong> 2.0, see Tim O’Reilly’s essay on this topic at<br />

http://www.oreillynet.com/pub/a/oreilly/tim/news/2005/09/30/what-is-web-20.html.<br />

In this chapter, we introduce the basics of Ajax programming <strong>and</strong> provide some sample<br />

Ajax elements you can integrate into your applications.This chapter is in no way<br />

comprehensive, but it will provide a solid foundation for future work with these technologies.<br />

Key topics covered include<br />

n The combination of scripting <strong>and</strong> markup languages used to create Ajax applications.<br />

n The fundamental parts of an Ajax application, which include issuing a request <strong>and</strong><br />

interpreting a response from the server.<br />

n How to modify elements of applications from previous chapters to create Ajaxenabled<br />

pages.<br />

n The availability of code libraries <strong>and</strong> where to find more information.

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

Saved successfully!

Ooh no, something went wrong!