By themselves, XHTML documents are not particularly interactive. They do have links which you can click on, but but without some kind of scripting or programming, web pages just sit there and do nothing. That's not necessarily a bad thing, but if you need them to interact with the user, you need to use
Forms. One way to make web pages slightly more interactive is to use forms. Forms allow users to type text, choose from lists of options, and submit information so that it can be collected. In order to collect that information, the web developer must use some sort of programming language to process the data.
JavaScript. JavaScript is a client-side scripting, or programming, language that allows web developers to use logic in web pages. You can say something like "if condition A is true, then do B, or else to C." It can get much more complex than that, but that's the basis for much of the logic made possible by JavaScript. The term "client-side" refers to the fact that the computations are all performed on the client's computer, rather than on the web server. JavaScript files must be completely downloaded to the user's computer. At that point, the browser can implement the logic in the JavaScript files. The advantage of client-side scripting is that it allows for fast interactions, because there is no need to send requests to the server or wait for responses. Disadvantages include the fact that users can turn off JavaScript, users can see all of the JavaScript code if they view the source code, and there are certain types of server interactions that are impossible with JavaScript alone.
Plugins. Plugins such as Flash, Shockwave, Quicktime, RealPlayer, Windows Media Player, etc. offer other types of interaction. Flash, in particular, boasts full-featured scripting capabilities, similar to JavaScript. The great advantage of plugins is that they can offer specialized services and features that would otherwise not be possible in plain XHTML files. One of the disadvantages of plugins is that in order for a user to take advantage of content created for plugins, the user must have the plugin installed on the computer.
Server-Side Scripting. Unlike JavaScript, all of the computation with server-side scripting is performed on the web server. This offers the advantage that users do not need to download the scripts. Also, some server interactions would be impossible otherwise. The disadvantage is that even small interactions must be sent to the web server, processed there, and responses returned to the user's browser. This can slow down the interaction considerably, especially if the internet connection is slow. Examples of server-side scripting languages include PHP, ASP, JSP, .net, Cold Fusion, Perl, and others.
AJAX. AJAX is the combination of JavaScript and server-side scripting. Some requests are sent to the server to be processed by a server-side programming language.. Others are processed on the client's computer using JavaScript. AJAX is often considered an integral part of the so-called "Web 2.0" experience, which represents a certain degree of maturation of web processes and user interaction, often with a collaborative social interaction component.

This work is licensed under a Creative Commons Attribution-Noncommercial-Share Alike 2.5 License.