|
Softpanorama |
May the source be with you, but remember the KISS principle ;-)
|
|
CGI |
Etc |
The author, Lincoln Stein <lstein@cshl.org> , June 19, 1998
Create Web CGI scripts in Perl with simplicity and elegance
When I first discovered the power of Perl for writing Web CGI scripts, I was on the top of the world. "I can do anything!" I thought. A few weeks later the gloss had worn away a bit as I found myself in the vexing position of rewriting the same tedious pieces of code multiple times, and, worse, making the same mistakes repeatedly. So I did what programmers have always done: I wrote a small subroutine library to make my life easier. I called it "CGI.pm." This library takes care of all the details of parsing fill-out forms, producing syntactically correct HTML, and creating the HTTP header. A complete interactive page can be as short and sweet as this one:#!/usr/bin/perl
use CGI ':standard';print header,
start_html(-title=>'Short and Sweet'),
h1("'Tis a Gift to be Simple"),
start_form,
"Type your name:",textfield(-name=>'Name'),
submit,
end_form;print "You entered ",param('Name') if param();
print end_html;
Over a long period of time, this library grew and became more sophisticated. I added support for frames, for cookies, for JavaScripting, and for such esoterica as server push. And as it grew, more and more people discovered it and began to use it for their own CGI scripting. When Perl 5.004 was released, it was adopted as the standard library for Perl CGI scripting.
With this book, I share with you all the secrets of CGI.pm, showing you how to use it to create elegant and sophisticated applications of your own, and how to extend and customize the library for your own purposes.
Customer Comments
Average Customer Review: **** Number of Reviews: 4A reader from Richmond, Virginia , August 30, 1999 ***
Information is invaluable but organization needs work
This is an invaluable book for using an invaluable library module (if you do CGI coding). There is absolutely no substitute for CGI.pm. However, this book is very frustrating to use because the Reference Guide section is organized into different weird categories instead of just listing all the functions in CGI.pm in alphabetical order (like in Perl books, for example). Therefore the reader has to try to figure out what category a function in the module belongs in in order to look it up. Very very aggravating! In fact I trained a group of developers in using CGI.pm and many of them avoided using it because it takes so long to find what you're looking for in the reference section of the book. I am hoping for a new edition of the book SOON with this problem corrected. The material is invaluable, but I have to give three stars because of poor organization.J_A_King@msn.com from San Francisco , January 14, 1999 *****
A Must Buy
Examples solve real life programming needs. It is a real time and life saver. (note to publisher:Print it darker. It is hard to tell difference between commas and periods.Joseph N. Hall (joseph@5sigma.com) from Chandler, Arizona , September 30, 1998 ****+
Excellent text; questionable typography
I've enjoyed this latest book of Lincoln's, and recommend it highly. This is an interesting book with many good examples. I am happily using it as a text in my Programming the World Wide Web classes. This is one of very, very few books on CGI programming that use fluent Perl (Perl 5 constructs in particular) *and* up-to-date language features (CGI.pm, obviously). The only drawback of the book, and the only reason I didn't give it 5 stars, is that I think the typography is lousy. In particular, the font for the code samples is too light, and the excessive leading in general makes the book harder to read. The book has its share of first printing typos, but then again, mine had them too, so I can hardly complain about that. :-) Good work, Lincoln!Larry Hunter (lhunter@acm.org) from Austin TX , June 18, 1998 *****
A potential winner with a few first-edition problems.
This book will be an absolute necessity for CGI programmers writing in Perl. It's a description of a must-use tool by the tool's creator. It goes well beyond the online and POD documentation for CGI.pm. The example code snippets and programs are well chosen. There are a few problems: the organization of the reference section is confusing, and the descriptions of table(), Tr(), and td() don't explain how to enter attributes. (But the table examples show how to do that, so it's not much of a problem.) Summary: if you write CGI in Perl, get this book and use it.
scalper@worldmailer.com from Framont, California. U.S.A , January 15, 1999
A best book for CGI beginner
I have bought 5 CGI books, only this one does teach me something from the beginning. By reading through the first chapter, I fully understand the structure of a site, what is the document root, why index page in the /usr/local/http/htdocs directory is automaticlly loaded if www.xxxx.com is used, as well as why cgi-bin is treated as in the same directory under the document root as your html document eventhough the cgi-bin is one level higher than htdocs, etc, ... These are all the questions I have in my mind since I started to learn CGI, this book enlightened me starting in the first chapter! (Certainly not only one chapter can do all). No other books take a approach as this one to teach you from the very beginning, which is very crucial to any one who is new to CGI I believe. This is a book for any one who wants to learn CGI from the very beginning. But I think if you have some html and unix knowledge, it would be much easier for you to quickly learn CGI by reading this book. I have one year html experience and know some basic unix and perl, I feel very comfortable reading through this book and finished with it just in a week. If you are looking for some advanced CGI, maybe O'Reilly's "Programming in CGI" will do much better for you.
**+ Building Cyberstores : Installation, Transaction Processing, and Management; Martin Nemzow
A simple overview of HTML, web design, and the internet
Nemzov eagerly catalogues a vast collection of factoids he has collected. The book is roughly organized into: how to build a web site, how complicated it can be dealing with an ISP, more web trivia about what to put in your web site, and some very dated opinions about outdated web sites.There is almost nothing on database integration, transactions, or the management of a commercial site, as had been promised in the subtitle.
This book is for non-technical managers who would like to sound cool but have no interest in the topic. There is no vision, no strategy, no direction, no future, nothing but a nonstop breathless recitation with an occasional banal opinion.
Mike Manning (mmanning@digev.com) from Los Angeles, CA , March 24, 1998
Just another fluff-filled tome
I bought this book hoping it would live up to some of its promises, and really give a detailed look a EDI or POS integration or transactions or tying into existing accounting systems (all bullet points on the back cover). I'll be returning it tomorrow because it failed to fulfill any of them. I was able to blast through this 500 page book in a single sitting because there wasn't a single new concept or piece of information to slow my reading...This would probably be a good intro to ecommerce for a novitiate, but it's a waste of time for anyone who's ever built a store before.
As side-notes, 1) I was amazed that any "tech-savvy" book could repeatedly mis-spell "embed" as "imbed" and 2) this book could have been dramatically improved by restructuring grouping of the information, and breaking long, winding chapters into more insightful, tight, shorter chapters.
Amazon.com A Glance Writing Apache Modules with Perl and C (Nutshell Series)
The Cgi/Perl Cookbook Craig Patchett, et al
A reader from Boston, MA , June 10, 1999
Great help for new CGI developers
My favorite Web development book! Great scripts, terrific explanations of how they work, and a style of programming and writing that is easy to understand for a change. (The installation instructions could have been better, but the explanation how the scripts work, which I was most interested in, was outstanding.) I'm not sure if I would recommend this book to someone who just wants ready-to-use scripts, but for anyone wanting to learn about CGI programming it's definitely a must-have.A reader from California , June 5, 1999
The code in this book is terrible
I friend of mine has this book, and I thought I'd take a look at a couple of the example they give, becaue I am trying to write a search engine. Their code, while basically funcional, has little real worth... the code is amateurish...A reader from Arlington, Virginia , May 28, 1999
Lots of code, some buggy and no real CGI security usage.
What I really needed was a CGI/PERL/Security book. What I got was This Book, and it went back to the store the next day. I didn't like that the first line of code I saw lacked the -T (taint) flag, and it must be a 5.003 bug or me, but I could not use PUSH to add my library to @INC, but instead had to USE it. www.booksonline (SCBC) is offering this book for $15, and that is about what its worth.
A reader from
California, US , August 23, 1998
Excellent technical book for CGI and ISAPI programming.
The examples were clear and helpful, the STL focus showed me some things I had
never done before with the stream iterators. This is the only worthwhile book
that shows how to do CGI programming in C++! The ISAPI and ODBC samples helped
me enable retail merchandise from my web site within a few weeks. Combined
with the credit card validation examples in C++ makes this recommended.
**+ Web Commerce Technology Handbook (McGraw-Hill Series on Computer Communication); Daniel Minoli, Emma Minoli
A reader from Connecticut , November 23, 1998
Exhaustively detailed tome
This work is an excellent up to date work covering the various components of e-commerce. It addresses not only the technical security issues regarding e-commerce but the advantages and disadvantages of particular e-commerce platforms and schemes. The author also presents a well thought out road map for the future of web commerce. This borders on being a scholarly work, as it is detailed and well documented. Therefore, I would NOT recommend this book for beginners (such as me) or those who are looking for a how-to book to get them up and running.
It seems to me that this is another book hastily scribbled together around a few buzzwords.
A reader , July 28, 1997
Look elsewhere if you want to do electronic commerce.
This book starts off with a useless introduction to the web followed by code
generated by Symantec Cafe. None of which did I find useful. The book doesn't
cover SET (secure electronic transactions) OR JECF (Java electronic commerce
framework). These are essential technologies for doing web commerce and should
have had coverage.
Instant Web Scripts With Cgi Perl
Selena Sol, et al / Paperback / Published 1996
Copyright © 1996-2008 by Dr. Nikolai Bezroukov. www.softpanorama.org was created as a service to the UN Sustainable Development Networking Programme (SDNP) in the author free time. Submit comments This document is an industrial compilation designed and created exclusively for educational use and is placed under the copyright of the Open Content License(OPL). Original materials copyright belong to respective owners. Quotes are made for educational purposes only in compliance with the fair use doctrine.
Standard disclaimer: The statements, views and opinions presented on this web page are those of the author and are not endorsed by, nor do they necessarily reflect, the opinions of the author present and former employers, SDNP or any other organization the author may be associated with. We do not warrant the correctness of the information provided or its fitness for any purpose.
Last modified: November 08, 2008