Have one to sell? Sell yours here
CGI and Perl in Easy Steps
 
See larger image
 
Tell the Publisher!
I’d like to read this book on Kindle

Don't have a Kindle? Get your Kindle here, or download a FREE Kindle Reading App.

CGI and Perl in Easy Steps [Paperback]

Mike McGrath , Computer Step
4.3 out of 5 stars  See all reviews (3 customer reviews)

Available from these sellers.


Amazon.co.uk Trade-In Store
Did you know you can trade in your old books for an Amazon.co.uk Gift Card to spend on the things you want? Plus, get an extra £5 Gift Certificate when you trade in books worth £10 or more before June 30, 2012. Visit the Books Trade-In Store for more details.

Product details

  • Paperback: 192 pages
  • Publisher: Computer Step (25 Jan 2001)
  • Language English
  • ISBN-10: 1840780274
  • ISBN-13: 978-1840780277
  • Product Dimensions: 22.6 x 18.2 x 1.4 cm
  • Average Customer Review: 4.3 out of 5 stars  See all reviews (3 customer reviews)
  • Amazon Bestsellers Rank: 1,184,770 in Books (See Top 100 in Books)
  • See Complete Table of Contents

Product Description

Book Description

This book will get the reader started in programming quickly and explains all the commonly used aspects of Perl. It is non-version specific and is suitable for anyone new to CGI (Common Gateway Interface) language, both for the experienced web developer who wants to get to grips with this powerful language, as well as for the first-time web developer with no prior experience.

Starting with "Perl Tools & Environment", this chapter introduces the world of CGI & Perl. It shows how to download and install the free Perl interpreter that is needed to run Perl scripts. The benefits and features of a purpose-built Perl editor are demonstrated, and there is a guide to download and install the free Xitami web server to create a local CGI Intranet environment.

The author then moves on to "Getting Started", in a chapter that illustrates a first Perl script and introduces the three variable types that are used to store information. Syntax rules of the Perl language are discussed and data joining (concatenation) is demonstrated.

Chapter Three demonstrates the many ways that Perl operators can manipulate script values and provides examples of each: Arithmetic, Assignment and Logical Operators; Numeric and String Comparisons; Conditional and Range Operators; Math Functions; Escape Sequences. Next, the author shows how to write statements in Perl script. Conditional branching is demonstrated and each type of loop statement is explained and illustrated.

"Using Arrays" is a chapter devoted to the array variable, which can contain multiple pieces of data. Areas covered are: Create An Array; Referencing Elements; Convert Scalar to Array; Fill Elements Loop; Address All Elements; Subarrays; Add/Remove First and Last Element; Combining Arrays; Replacing Elements; Sort Alphabetically and Numerically; Slice and Reverse.

"Using Hashes" covers the hash variable type that is so important to handling HTML form data in CGI scripts. A hash variable is a special type of array that arranges its data in pairs that form an "associative array". This chapter provides examples and demonstrates how to usefully handle the hash data in Perl scripts. The author then moves on to "Subroutines" and describes by example, how subroutines can be useful to define pieces of code that can be used repeatedly in a Perl script.

Chapter Eight illustrates how "Perl Functions" are useful in CGI scripting. Time and Currency formatting are demonstrated along with random number generation. Other useful functions covered are: Random Generator; Random Floats; Data Formatting; Currency Format; Handling Time; Chop String; Chomp New Lines; Eval; Warn and Die; Pack.

Next, performing "Pattern Matching" is covered, by demonstrating how located matches can be manipulated in a variety of useful ways. This chapter also introduces 'Regular Expressions' to search through a string for a specified substring. Further areas covered are: Match String; View Match; Substitute String; Split Pattern; Translate; Character Classes; Inclusive and Exclusive Groups; Limited and Optional Matching; Minimum, Alternative and Multiple Matches.

Chapter Ten looks at "CGI from Web Pages" and demonstrates how web pages can interact with Perl script using CGI. Different methods of sending data from the browser to the server are demonstrated. The form parser is detailed in full, and examples are given in sending data back to the browser.

The author then moves on to "Working with Files" and illustrates how Perl CGI scripts can read and write text files on the server. There are demonstrations of how these features can be used to create a simple hit counter and guest book. Next, a chapter on " Handling Directories" illustrates how to work with files and directory structures. Creation and deletion of directories is demonstrated. File permissions are explained with examples of how they can be changed by Perl scripts.

"Data Persistence" illustrates how user data can be retained as the user browses across different web pages. These are demonstrations on how to store data in hidden firms, in server files and in browser cookies. Also examples are provided that demonstrate how access to cookie information is restricted.

Moving on to "Form Inputs", this chapter demonstrates how Perl CGI scripts can use different types of HTML form input from check boxes, radio buttons, and options menus. Also examples show how Perl can navigate between web pages and send email. Lastly a survey application illustrates some of these features in use.

The final chapter "Upload and Run Scripts", demonstrates how to upload Perl CGI scripts to a web server so that the scripts will perform correctly. Examples illustrate how scripts can be restricted to run only from origins on the same server. Using third-party scripts and libraries is explained with addresses where CGI resources can be obtained for free.

PUB COMMENTS: Mike McGrath is an expert on web development and has written other best selling in easy steps titles including 'WAP in easy steps' and 'JavaScript in easy steps'.


Tags Customers Associate with This Product

 (What's this?)
Click on a tag to find related items, discussions, and people.
 
(1)

Your tags: Add your first tag
 

Sell a Digital Version of This Book in the Kindle Store

If you are a publisher or author and hold the digital rights to a book, you can sell a digital version of it in our Kindle Store. Learn more

Customer Reviews

4 star
0
2 star
0
1 star
0
Most Helpful Customer Reviews
9 of 10 people found the following review helpful
By A Customer
As a professional client-side web developer, I finally came to a point where I had to learn some Perl for more advanced interactivity and control. Much of my needs are CGI and forms, with a fair share of server side scripting. Now, I have several Perl books on my desk, including a couple of very thick ones. The one that has become worn out most is this "Easy Steps" book.

If one has at least a little understanding of Javascript and a vague idea of Perl syntax which are somewhat similar, and has experience in HTML (else why would he need Perl?), for him this book is a major time-saving aid. It is like a good "build-it-yourself" book for a home master. If you are sort of a handyman, then a little clever guidance, tips and examples that you can follow can lead you to accomplish a lot even if you do not fully know how an electrical tool works or what cement mix consists of.

In fact, most of the Perl tasks that a typical web developer faces boil down to a rather simple CGI. Unless excess skill costs are of no concern, it DOES NOT take a Perl guru to build forms, make cookies or install passwords... It takes a little learning effort and a good manual. Which this book is.

When I went through "Perl & CGI in Easy Steps" for the first time, I made a note of what I can turn to it for, and since then have been opening it over and over again.

Good job, Mr. McGrath. I only wish those examples were available on line for copy and paste - would save even more time for Perl students and practitioners.

Comment | 
Was this review helpful to you?
I paid the grandiose sum of 1p to by this old book. Perl may not be everyone's choice, but this is one way of getting started on interactive web design.
Comment | 
Was this review helpful to you?
6 of 9 people found the following review helpful
By A Customer
I found this book confusing to say the least. I was looking for a basic guide for someone who has not had any experience in Perl & CGI, and I have found a book which explains everything twice (once in a normal way and then again later in a more confusing way). I did find it very easy on the eyes as it had some nice screen shots but after getting to chapter fourteen I looked at the code and thought "I haven't learnt a thing!". Confusing and a bit of a bad training book, but I have to admit it would be a good reference book for debugging simple code or adding basic operations. It would have been better if it had some form of test after each chapter, rather than a written example which can be just copied exactly and it works without any effort.
Comment | 
Was this review helpful to you?
Search Customer Reviews
Only search this product's reviews

Customer Discussions

This product's forum
Discussion Replies Latest Post
No discussions yet

Ask questions, Share opinions, Gain insight
Start a new discussion
Topic:
First post:
Prompts for sign-in
 

Search Customer Discussions
Search all Amazon discussions
   


Listmania!

Create a Listmania! list

Look for similar items by category


Look for similar items by subject


Feedback