For whatever reason I am having trouble finding a list of rules to follow when coding Perl. I am developing my own list and here is what I have:
Always begin your Perl programs by calling 'use strict' which enforces declaration of variables and other proper coding practices. Failure to call 'use strict' means, for instance, that typos in variable names may not be caught.
When declaring Perl variables you should set their scope using the 'my' keyword. Only make your variables global if there is some reason for them to be global. Do not declare your variables as 'local' as this keyword in Perl has a special meaning and is intended only for backwards compatibility and for very special cases.
Name your variables consistently throughout your script. One approach is use lowercase for the first letter of the first word of a variable name, uppercase for the first letter of all other words in a variable name, and lowercase for all other letters. Another approach is to separate all words in variable names using underscores.
All Perl filehandles should be in all uppercase.
When doing CGI programming always use CGI.pm, e.g., 'use CGI qw(:standard)'
When doing CGI always (very important) retrieve variables from forms using CGI.pm's param() function.
Never attempt to parse the form variables directly, as special characters in the form variables such as spaces will probably break your script.
If you need to install a Perl module download it from www.cpan.org. CPAN is the standard repository for Perl modules. Avoid using modules which are not listed at CPAN.