4.16 System Administration4 Labs4.14 awk - A Programming Language4.15 perl -- A programming Language

4.15 perl -- A programming Language

perl is a programming language developed and supported by Larry Wall currently employed by O'Reilly & Associates, Inc.. It is an interpreted programming language with good string handling capabilities. It accounts for a lot of the CGI programming that is done on the WWW.

Look at these two books:

You may also want to look at the URLs:

There are two programs you may want to look at:

In this lab I would like you to:

  1. Create, if necessary, the directory ~/public_html/ in your home directory.
  2. Create, if necessary, the directory cgi-bin in your existing directory ~/public_html/.
  3. Make this new directory your working directory.
  4. Copy three files into this directory. perl.cgi, data, and sed.text from /home/cis137/perl.cgi
    cp /home/cis137/perl.cgi /home/cis137/data /home/cis137/sed.text .
    

    These files are also avaliable at:
    http://uml.lt.tucson.az.us/hl2.2007-fall/files/

  5. Set the permissions so that you can run the program as a CGI script. Set the data files to world readable. When the program is run it might not be run as you.
  6. To verify that the hhtpd is running correctly, run this program now. Do not proceed if you can't get this to work. The URL to access this program is:
    http://gort.edu-domain.pima.edu/~user-name/cgi-bin/perl.cgi 
    
  7. Modify the program so that it does the last part of the awk lab, NOT the awk program that I wrote.
  8. Add your name and the class number, "CIS137", to your output.
  9. Turn in a printed output of your results from a web browser. The URL to access your page will be:
    http://gort.edu-domain.pima.edu/~user-name/cgi-bin/perl.cgi
    
your-name
TABER CIS137
Lab 4.15: perl 

Instructor: Louis Taber, louis.taber.at.pima at gmail dot com (520) 206-6850
My web site in Cleveland, OH
The Pima Community College web site


4.16 System Administration4 Labs4.14 awk - A Programming Language4.15 perl -- A programming Language