![]() | 会員なら、この商品は10%Amazonポイント還元 (ポイントが表示されている場合は、表示ポイント+10%還元)。 |
Perl is one of the most popular scripting languages for adding powerful interactive features to Web pages. Perl lets you place forms on your site that collect and process user input such as comments and product orders; enables visitors to search for information; and can integrate a database into your site, among its many other capabilities. Perl and CGI for the World Wide Web, 2nd Edition: Visual QuickStart Guide fully revised and updated since its original 1998 release, gets users to the core of CGI scripting with Perl. Even first-time programmers will be able to create useful, workable scripts from scratch, or adapt and customize existing scripts to their own needs. Hundreds of screen shots and clear, easy-to-understand directions make this the perfect Perl book for beginners, as well as a handy reference for those with previous programming experience.
登録情報
|
Admittedly, the coverage of the subject is a little light, and the hold-the-novice-user-by-the-hand- style was actually confusing (she should have used the more standard method of using bold, italics, and monospace fonts to indicate output, user required input, and variables) BUT considering I was at the absolute beginner level with respect to Perl and CGI, I feel the book lived up to my expectations. I wanted something to get me started quickly, and not to assume I knew anything about CGI and PERL but did assume that I knew HTML. I did not want a book that would cover the subject matter exhaustively, just give me a basic "Quick-Start" which it did quite well.
I continued to use the book as a reference for a few months, though it's really not laid out well for that purpose. (I would suggest the O'Reilly Perl CD Bookshelf for that) If you know PERL and CGI basics, this one is not for you, but if you're comfortable with HTML and want to start doing more, It's worth a try.
The second edition does add much that was missing from the first edition, such as the "use strict" pragma that forces programmers to declare variables, and the CGI.pm library that, for one, circumvents the tedium of parsing form data. Arguably the most important edition, however, is the discussion of setting up a local test environment, but it is also in this area that the book falls short.
In particular I find it bothersome that the author does not recommend installing Apache as a test environment. After all, Apache is the environment under which most CGI scripts will eventually run on virtual web hosts running the Linux/Unix operating system.
So by testing with Apache for Windows, you will be emulating the actual production environment of the script much more closely than by using the other web servers that are recommended. In fact, there are a number of (free) products on the market that bundle Apache and Perl together, so that you don't have to go through the extra step of downloading and installing Perl seperately from the web server software, as in the book's examples.
Another sin of omission is that no consideration is given to the persistent storage of data, other than cumbersome text files. However, this has been one of the areas in which the greatest strides have been made since the first edition. Retrieval and storage of data from web applications, using some sort of database, are practically a given today.
Perhaps the author thought that a discussion of the Perl DBI (Database Interface) would be too much of a digression, and would involve setting up additional database software. However, a few of the same bundles I mentioned above not only include Apache and Perl, but also the mySQL database engine.
At the very least I think there should have been discussion of the very simple "DBM" database system available on almost all Unix systems. Perl makes it very easy to store hash arrays to disk in this format, and just as easy to import them into hashes. This would at least provide readers with a stepping stone to eventually investigating the more robust DBI library.
So I rate the content a 5, but I take off one point for what the book lacks.
|