When to Use Perl

When designing an interactive Web site, you have a wide choice of languages to develop in. Not even CGIs have to be written in Perl. Some languages, such as PHP and ASP, are embedded into HTML pages, and other languages, such as C, are compiled and can offer high performance. So when should you use Perl?

There are some circumstances in which it is convenient to be able to write standalone scripts with no need for a Web server; for instance:

  • You may want to invoke programs directly from the command line; you can do this easily with Perl.

  • You may want to invoke programs from the cron scheduler. If, for example, you have a database that needs a regular update, perhaps a once-nightly process to be run, you can write the application ...

Get Sams Teach Yourself MySQL in 21 Days, Second Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.