The online documentation for Perl, called manpages due to their UNIX origin, has been divided into separate sections so you can easily find what you are looking for without wading through hundreds of pages of text. Since the top-level manpage is simply called perl , the UNIX command man perl should take you to it.[ 1 ] That page in turn directs you to more specific pages. For example, man perlre displays the manpage for Perl's regular expressions. The perldoc command may work when the man (1) command won't, especially on module documentation that your system administrator may not have felt comfortable installing with the ordinary manpages. On the other hand, your system administrator may have installed the Perl documentation in hypertext markup language (HTML) format, especially on systems other than UNIX. If all else fails, you can always retrieve the Perl documentation from CPAN; look for this information in Section 0.5, "How to Get Perl" ."
Here are the principal manpages included with the 5.004 distribution of Perl:
The Perl newsgroups are a great, if sometimes cluttered, source of information about Perl. comp.lang.perl.announce is a moderated, low-traffic newsgroup for Perl-related announcements. These often deal with new version releases, bug fixes, new extensions and modules, and Frequently Asked Questions (FAQs).
The high-traffic comp.lang.perl.misc group discusses everything from technical issues to Perl philosophy to Perl games and Perl poetry. Like Perl itself, comp.lang.perl.misc is meant to be useful, and no question is too silly to ask.[ 2 ]
The comp.lang.perl.tk group discusses how to use the popular Tk toolkit from Perl. The comp.lang.perl.modules group is about the development and use of Perl modules, which are the best way to get reusable code. There may be other comp.lang.perl.whatever newsgroups by the time you read this; look around.
One other newsgroup you might want to check out, at least if you're doing CGI programming on the Web, is comp.infosystems.www.authoring.cgi . While it isn't strictly speaking a Perl group, most of the programs discussed there are written in Perl. It's the right place to go for web-related Perl issues.
If you have access to the World Wide Web, visit the Perl home page at http://www.perl.com/perl/ . It tells what's new in the Perl world, and contains source code and ports, documentation, third-party modules, the Perl bugs database, mailing list information, and more. This site also provides the CPAN multiplexer, described later.
The Perl Frequently Asked Questions (FAQ) is a collection of questions and answers that often show up on comp.lang.perl.misc . In many respects it's a companion to the available books, explaining concepts that people may not have understood and maintaining up-to-date information about such things as the latest release level and the best place to get the Perl source.
Since the 5.004 release of Perl, the FAQ has been included with the standard distribution's documentation. Here are the main sections, each available as its own manpage:
In the unlikely event that you should encounter a bug that's in Perl proper and not just in your own program, you should try to reduce it to a minimal test case and then report it with the perlbug program that comes with Perl.
Perl is distributed under either of two licenses (your choice). The first is the standard GNU Copyleft, which means, briefly, that if you can execute Perl on your system, you should have access to the full source of Perl for no additional charge. Alternately, Perl may also be distributed under the Artistic License, which some people find less threatening than the Copyleft (especially lawyers).
Within the Perl distribution, you will find some example programs in the eg / directory. You may also find other tidbits. Poke around in there on some rainy afternoon. Study the Perl source (if you're a C hacker with a masochistic streak). Look at the test suite. See how Configure determines whether you have the mkdir (2) system call. Figure out how Perl does dynamic loading of C modules. Or whatever else suits your fancy.
Programming Perl is the definitive reference book on Perl, whereas this book is more of a tutorial. If you want to learn more about Perl's regular expressions, we suggest Mastering Regular Expressions , by Jeffrey E.F. Friedl (also published by O'Reilly & Associates).
Also check out O'Reilly and Associates' CGI Programming on the World Wide Web by Shishir Gundavaram; Web Client Programming with Perl by Clinton Wong; and HTML: The Definitive Guide, Second Edition , by Chuck Musciano and Bill Kennedy.
The AWK Programming Language , by Aho, Kernighan, and Weinberger (published by Addison-Wesley), and sed & awk , by Dale Dougherty (published by O'Reilly & Associates), provide an essential background in such things as associative arrays, regular expressions, and the general world view that gave rise to Perl. They also contain many examples that can be translated into Perl by the awk -to- perl translator, a2p, or by the sed -to- perl translator, s2p . These translators won't produce idiomatic Perl, of course, but if you can't figure out how to imitate one of those examples in Perl, the translator output will give you a good place to start.
For webmasters, we recommend the second edition of How to Setup and Maintain a Web Site , by Lincoln Stein, M.D., Ph.D. (published by Addison-Wesley). Dr. Stein, renowned author of Perl's CGI.pm module (described in Chapter 19, CGI Programming ), delivers a professional and comprehensive treatment of all issues related to administering a web site on UNIX, Mac, and Windows platforms.
We also recommend Johan Vromans's convenient and thorough quick reference booklet, called Perl 5 Desktop Reference , published by O'Reilly & Associates.