CSCI A348
Mastering the World-Wide Web

Spring `96 Lesson
Haiku Perl Program Development Example

The following series of scripts illustrate the stages of development of a sample Perl utility to serve as a dual command line front-end and CGI interface to a random word haiku generator. Any program text added since the previous version is listed in bold, and any changed since the previous version is in italics.

Development version 00: run spew command
Development version 01: add minimal PATH
Development version 02: add full PATH
Development version 03: use open() instead of system()
Development version 04: add number argument and usage message
Development version 05: uppercase first word of haiku
Development version 06: add multi-line haiku format with command line flag
Development version 07: eliminate redundant blank line in multi-line haiku
Development version 08: add HTML markup with command line flag
Development version 09: add dictionary links with command line flag
Development version 10: fix behavior with an undefined dictionary URL
Development version 11: add full text of HTML page
Development version 12: arrange all HTML text segments to DATA section
Development version 13: suppress dictionary paragraph when no dict links
Final version: add CGI header to HTML output

Run the final version.

<kinzler@cs.indiana.edu> 22 January 1996