#!/usr/local/bin/perl # # sample.cgi - A sample CGI script that generates pages with the # same look-and-feel as the CS Departmental Pages. # # robh 10/2001 # # Define the head and tail html files you wish to use. These are # of the form /l/www/CATEGORY/{headonly,tailonly}.html where # CATEGORY controls the navigation menu item that is expanded # and is one of the following: # # Contacts Courses Academics Research People Calendar Resources Facilities # # If you don't want any of the categories to be expanded, just use # /l/www/Support/{headonly,tailonly}.html. # $head="/l/www/Support/headonly.html"; $tail="/l/www/Support/tailonly.html"; # # Generate the Content-type header # print "Content-type: text/html\n\n"; # # Print out the header # open(HEAD,"< $head") || die "unable to open $head"; while (
) { print; } close(HEAD); # # Generate your content # print "