Header and Body Anatomy of Server Response

Domain Hosting image
Web Hosting
Dedicated server
ssl certificate
Web Design image
Email

The best way to understand how to format information for output is to review how the browser, server, and CGI program communicate and to dissect the server response. The server accesses the file, adds some of its own headers and sends it to the browser.

The Web browser begins the process by asking the server to retrieve some file or to run some CGI program. If asked to retrieve a file, the server looks to see if the file exists. If it does, the server then determines what kind of file it is. The server then tells the browser whether it was successful in retrieving the information, what kind of data it's about to send, and then sends the data itself. For now, you're primarily interested in how the server speaks to the browser.

Here's an example that demonstrates exactly how this process works. On our fictitious Web server our server.org, we have the file hello.html.

The hello.html file. <html><head><title>Hello World</title></head>
<body>
<h1>Hello World</h1>
</body>
</html>



Domain Name Search

www.


Copyright (C) 2007. Web Domain design hosting. All rights reserved.