From LQWiki
HTTP (HyperText Transfer Protocol)
HTTP is a protocol for handling exchanges between an HTTP client (usually a web browser) and an HTTP server (or web server). In other words, HTTP is the medium through which a user is able to read web pages. It was created in 1992 by Tim Berners-Lee, who was then working at Cern, mainly to provide himself and his colleagues with an easy way to share their work.
Here is the process:
- A user wishes to view a web page.
- He types the address (or URL) of the page into a web browser.
- The browser initiates the connection by sending a request string to the server (note that the server never initiates the communication. A request from the user must take place first, and a good thing too, otherwise we would be even more overrun with viruses than we already are. This is why HTTP is often described as a request/response protocol).
- HTTP request strings are sent in plain text, usually over port 80, and look something like this:
GET /index.htm HTTP/1.0
Roughly translated, this means: "Hi, I speak HTTP 1.0! PleaseGETme the pageindex.htmwhich is located at the top level (/) of your domain. Thanks!" - Having received the request, the server will look for the requested file. If it finds it, it will send it to the requesting client (again in plain text). If it doesn't find the file, it will send its error page instead (you've seen this a million times -
error 404; the page cannot be found). Other things can go wrong too, like the server being too busy or not able to open the file for some reason. But generally, the client should receive some HTML it can use. All pages sent by the server are preceded by an HTTP header which provides some basic information to the client about how the document ought to be rendered. - At this point the connection is severed and both machines forget about each other until the next request. HTTP is referred to as a stateless protocol, because no information about the state of the connecting machine is retained (in theory). Consequently servers do a fair amount of work establishing connections, and lots of techniques have been developed to maintain persistent information between servers (cookies and Flash are examples of this). However, all this extra work is preferable to having connections stay open over longer periods, which would allow servers to push information at a user even if he or she hadn't requested it. Even back in 1993 this was recognised as a danger.

This page is available under a