You may work on this assignment with a partner if you wish. In this assignment, you (and your partner) will create a
simple two-page web site that uses a form to provide the parameters to a web server. You will implement both the CGI
and PHP versions of this website..
– To demonstrate the operation of server side technologies (CGI and PHP)
– To demonstrate the ability to create user web forms
1. Two HTML forms that are identical, except where the CGI implementation uses the form GET method and the
PHP implementation uses the form POST method.
2. Each of the HTML forms must:
b. Ask the user (by name) to choose an animal from a list of six animals (you choose which six)
i. use a combo-box / drop-down / select list for this control
ii. make the default selected (or first) option in the dropdown blank
iii. you will need to validate that the user has then actually chosen an animal from the list before
c. Once validated, the user’s name and the animal selection are to be sent to the server as appropriate key
value pairs, in each of the two HTML pages, respectively.
d. Name the HTML files cgi-zoo.html and php-zoo.html.
3. The root folder of your web site on the server is to contain the two HTML pages as well as the CGI executable
and PHP server-side page.
4. A sub-folder called theZoo exists in your site.
a. This directory contains images of the 6 animals you chose as well as 6 short descriptions (text files)
corresponding to the animals.
i. The animal descriptions can be made up of a bullet-list of facts about the animal, a short
paragraph description or story of the animal, etc.
b. Each server technology composes the response, with:
i. A salutation to the person (using the name entered in the HTML form)
ii. The picture being displayed (no larger than 400 pixels x 400 pixels)
iii. The description of the animal – to be placed beside the picture
c. Remember when referencing your image files and text files to avoid using absolute file addressing
5. For the CGI solution, the server file must be called animals.exe and can be created using either C, C++ of C#. For
the PHP solution, the server file must be called animals.php
6. You are not required to make the pages overly fancy, but a reasonable amount of effort should be made to align
the content well.
7. Good programming practices must be exhibited as per SET standards. Make sure to comment all source files
When submitting your solution to this assignment, hand-in a single ZIP’d file containing:
1. The two HTML Animal-Serve launching pages (HTML files)
2. The cleaned solution for the CGI executable file
3. The PHP server-side source file
4. The supporting folder (correctly named to match your code) with appropriate files (animal images and textual
5. If you’re doing this assignment with a partner, then please ensure you include both partner names in your file
header comments (in HTML, CGI source and PHP source)
6. Also remember that this solution will be tested using Internet Explorer v11 as well as Chrome