CIS 33A - Programming in PERL

Summer Session 2009 - De Anza College

Assignment-5 (Due Saturday, 08/08 - at midnight)

 

Instructions: Write a program named monitor that produces a simple web page named monitor.html. The page should reflect the status of four types of Yahoo! Alerts received by my mam-p@voyager.deanza.edu account: Daily News, Health News, Horoscopes, and Weather. Note that each category of Daily News alert is sent via a separate email digest, so each category is given its own row in the monitor table.

Each table cell should contain one of two things:

  1. The actual date and time the email was received, which can be gleaned from the mail header that looks like this:
    Received: from mailgw.fhda.edu (mailgw.fhda.edu [153.18.96.107])
            by voyager.deanza.edu (8.12.11.20060308/8.12.10) with ESMTP id m6P80PYd0 30178
            for ; Thu, 30 Jul 2009 12:00:26 -0700
    

    The table cell should contain just the final portion of this three-line header, i.e., that part starting with "Thu, 30 Jul" above.

  2. Red background with the word "Missing!" on top.

The program should take two arguments:

  1. The number of days of data to display.

  2. The pathname of the mailfile which contains the alerts. In this case, you'll need to give your program the pathname to a readable copy of my mailfile. I've placed a recent copy in /tmp/mam-p.

To hand in your assignment, send me one and only one email with one separate text-file attachment named as specified above. The Subject line should be Perl ASSIGNMENT-5. Please put your name as it appears in De Anza College records in the body of the message.