![]() |
CGI-HTTP Headers![]() ![]() ![]() ![]() ![]()
Before looking at how the server responds to a request to run a CGI program first dissect the HTTP header. The first line of the server response is always I , status message and is called the status header, It tells you whether or not the server was successful finding the file. The format of this line is HTTP/1.0 number message where " number " is the status number and " message " is the status message. A status number of 200 means the retrieval was successful. HTTP/1.0 is the protocol type and version. Skipping down a few lines, notice the line Content length: 98. This tells the browser how large the data following the headers is in bytes. If you count the number of characters, including the invisible newline characters as a character, you will find that there are 98 of them, The last two fields of the line, represent the status code and content length, respectively, the same information that is returned by the server to the browser in the HTTP header. The Date header returns the date of the request according to the server. The Last Modified header returns the date and time. The Server header gives the name and version number of the server. Finally, the Content Type header tells the browser what kind of information to expect. text/html is the multipurpose Internet Mail Extension (MIME) type of HTML files. MIME is a way of describing the type of data.
|
|
CGI
Advantages of CGI
How CGI Works
Compiled Versus Interpreted
Input to CGI
CGI Introduction Program
HTML Forms
Accepting Input from the Browser
CGI Environment Variables
Get Versus Post Method
Get Method
Post Method
Sample <FORM> Based CGI Program
Complete Example for <FORM>
Output from CGI
Header and Body:Anatomy of Server Response
HTTP Headers
Carriage Returns and Newlines
Formatting Output CGI Common MIME TypesLocation Header Useful HTTP Stautus Codes Other Headers Dynamic Pages Sending Images Displaying the Current Date Feedback Form Program Server Side Includes Server Side Include Environment Variables Displaying the Date with Date Counter Example of SSI Counting the Number of Accesses Better Approach Towards CGI Program Client Versus Server Accessing a HTML Document Submitting a Form Accessing a CGI Program Databases ODBC Creating a DSN Win32::ODBC Module Creating a Table Inserting Data into a Table Deleting Data from a Table
Updating Data in a Table
Selecting Data from a Table Operating Systems Security Securing Your Web Server Writing Secure CGI ProgramWeb DesignDomain Names Home
FAQ
My Account
IP Address
SSL Certificates DNSWeb Hosting Web Server Cheap Web Design Dedicated web hosting Managed web hostingE Commerce Principles of E-Commerce E-Banking Electronic Payment System E-Security Credit Cards Smart Cards
The Mailbox POP Server SMTP Server IMAP Protocol |
| Home | Web Hosting | Web Design | Sitemap |
| Copyright (C) 2007. Web Domain design hosting. All rights reserved. |