Mike Gossland's Perl Tutorial Course for Windows

Course Intro

Introductory Perl Tutorial Course for Windows

This introductory Perl tutorial course for Windows will introduce you to the beginning concepts of Perl.

I wrote this course as an accompaniment to a classroom course in Perl, but now this website is visited by Perl students from around the world.

If you are following this course on your own, please follow it in sequence. The ideas are presented so that each section builds on the sections before. Please email me at perlcourse@gossland.com if you have comments or questions about the content.

Course Prerequisites

A student should be familiar with basic operation of a computer, how to open a DOS session, how to download and install a software package. Familiarity with at least one other programming language is not required, but it would be a definite asset. Since this course is directed at CGI programming, it is understood that the student should have a good working knowledge of HTML.

Note on typeface conventions: Throughout this site, the font of this paragraph is for the instructional content. Sometime it is indented to set off the sample text. This font is descriptive rather than rigorous, so it is not "ready to run" as a perl script. Don't expect to run text in this font without getting errors.

The following font is used for code:

# This type of text represents real perl code that
# is intended to be copied from the browser
# and pasted into your perl scripts. Each block
# should run as is.

Also, later in the course some of the perl scripts will be displayed in their own windows. You can save these as text files, or copy and paste the window contents into text files and then save them. Be aware that these are actually HTML pages and not plain text, so be careful when you save them that they turn out as just plain text.

Course Outline

  1. Course Intro
    1. Course Intro
  2. Perl Intro
    1. What's Perl
    2. Task Examples
    3. Running Perl
    4. Variables
    5. Flow Control
    6. Simple Scripts
  3. Matching
    1. Introduction
    2. Binding Op
    3. Reg Expressions
    4. Examples
    5. Substitution
    6. Advanced
  4. Functions
    1. Introduction
    2. String Functions
    3. Array Functions
    4. Test Functions
    5. User Functions
  5. Files
    1. IO Introduction
    2. STDOUT
    3. Writing to Files
    4. Reading from Files
    5. Reading Directories
    6. Editing File Contents
    7. Recursive Editing
  6. CGI Intro
    1. Intro to CGI
    2. First Page
    3. Printing HTML
    4. Serving HTML
    5. Serving Edited
  7. CGI Module
    1. Intro to GET
    2. CGI Module
    3. Handling Forms
    4. Form Errors
    5. Fatal Errors
  8. CGI In Use
    1. CGI In Use
    2. Site Search
    3. Presenting Data
    4. Cookies
  9. In Conclusion
    1. Final Remarks