Book description
“I picked up a copy of JavaScript by Example over the weekend and wanted to thank you for putting out a book that makes JavaScript easy to understand. I’ve been a developer for several years now and JS has always been the “monster under the bed,” so to speak. Your book has answered a lot of questions I’ve had about the inner workings of JS but was afraid to ask. Now all I need is a book that covers Ajax and Coldfusion. Thanks again for putting together an outstanding book.”
–Chris Gomez, Web services manager, Zunch Worldwide, Inc.
“I have been reading your UNIX® Shells by Example book, and I must say, it is brilliant. Most other books do not cover all the shells, and when you have to constantly work in an organization that uses tcsh, bash, and korn, it can become very difficult. However, your book has been indispensable to me in learning the various shells and the differences between them…so I thought I’d email you, just to let you know what a great job you have done!”
–Farogh-Ahmed Usmani, B.Sc. (Honors), M.Sc., DIC, project consultant (Billing Solutions), Comverse
“I have been learning Perl for about two months now; I have a little shell scripting experience but that is it. I first started with Learning Perl by O’Reilly. Good book but lacking on the examples. I then went to Programming Perl by Larry Wall, a great book for intermediate to advanced, didn’t help me much beginning Perl. I then picked up Perl by Example, Third Edition–this book is a superb, well-written programming book. I have read many computer books and this definitely ranks in the top two, in my opinion. The examples are excellent. The author shows you the code, the output of each line, and then explains each line in every example.”
–Dan Patterson, software engineer, GuideWorks, LLC
“Ellie Quigley has written an outstanding introduction to Perl, which I used to learn the language from scratch. All one has to do is work through her examples, putz around with them, and before long, you’re relatively proficient at using the language. Even though I’ve graduated to using Programming Perl by Wall et al., I still find Quigley’s book a most useful reference.”
–Casey Machula, support systems analyst, Northern Arizona University, College of Health and Human Services
“When I look at my bookshelf, I see eleven books on Perl programming. Perl by Example, Third Edition, isn’t on the shelf; it sits on my desk, where I use it almost daily. When I bought my copy I had not programmed in several years and my programming was mostly in COBOL so I was a rank beginner at Perl. I had at that time purchased several popular books on Perl but nothing that really put it together for me. I am still no pro, but my book has many dog-eared pages and each one is a lesson I have learned and will certainly remember. “I still think it is the best Perl book on the market for anyone from a beginner to a seasoned programmer using Perl almost daily.”
–Bill Maples, network design tools and automations analyst, Fidelity National Information Services
“We are rewriting our intro to OS scripting course and selected your text for the course. It’s an exceptional book. The last time we considered it was a few years ago (second edition). The debugging and system administrator chapters at the end nailed it for us.”
–Jim Leone, Ph.D., professor and chair, Information Technology, Rochester Institute of Technology
“Quigley’s book acknowledges a major usage of PHP. To write some kind of front end user interface program that hooks to a back end MySQL database. Both are free and open source, and the combination has proved popular. Especially where the front end involves making an HTML web page with embedded PHP commands. “Not every example involves both PHP and MySQL. Though all examples have PHP. Many demonstrate how to use PHP inside an HTML file. Like writing user-defined functions, or nesting functions. Or making or using function libraries. The functions are a key idea in PHP, that take you beyond the elementary syntax. Functions also let you gainfully use code by other PHP programmers. Important if you are part of a coding group that has to divide up the programming effort in some manner.”
–Dr. Wes Boudville, CTO, Metaswarm Inc.
The World’s Easiest Perl Tutorial–Fully Updated!
Perl byExample, Fourth Edition, is the easiest, most hands-on way to learn Perl. Legendary Silicon Valley programming instructor Ellie Quigley has thoroughly updated her classic to deliver the skills and information today’s Perl users need most–including all-new coverage of MySQL database programming and a Perl QuickStart designed to get experienced users up and running fast.
Quigley illuminates every technique with focused, classroom-tested code examples, detailed line-by-line explanations, and real program output. This exceptionally clear, easy-to-understand book takes you from your first Perl script to database-driven applications. It’s the only Perl book you’ll ever need!
New in this edition:
Perl programming QuickStart: makes first-time Perl programmers productive in just twenty pages
All-new chapter on using the Perl DBI with the MySQL database–plus an easy SQL primer to quickly get you started programming any database
New introductions to Perl in biology (bioinformatics) and to mod_perl, a Perl interpreter embedded in the Apache server, which allows you to create fast, dynamic content; manage the Apache server; authenticate users; and much more
Completely updated:
Includes many new and completely rewritten code examples
Contains fully revised CGI coverage for building dynamic Web sites with Perl
Covers modern Perl 5.8 concepts and principles–and provide
Table of contents
- Copyright
- Praise for Ellie Quigley’s Books
- Preface
- Acknowledgments
- 1. The Practical Extraction and Report Language
- 2. Perl Quick Start
-
3. Perl Scripts
- 3.1. Script Setup
- 3.2. The Script
- 3.3. Perl at the Command Line
- 3.4. What You Should Know
- 3.5. What’s Next?
-
4. Getting a Handle on Printing
- 4.1. The Filehandle
- 4.2. Words
- 4.3. The print Function
- 4.4. The printf Function
- 4.5. What You Should Know
- 4.6. What’s Next?
-
5. What’s in a Name
- 5.1. About Perl Variables
- 5.2. Scalars, Arrays, and Hashes
- 5.3. Reading from STDIN
-
5.4. Array Functions
- 5.4.1. The chop and chomp Functions (with Lists)
- 5.4.2. The exists Function
- 5.4.3. The delete Function
- 5.4.4. The grep Function
- 5.4.5. The join Function
- 5.4.6. The map Function
- 5.4.7. The pack and unpack Functions
- 5.4.8. The pop Function
- 5.4.9. The push Function
- 5.4.10. The shift Function
- 5.4.11. The splice Function
- 5.4.12. The split Function
- 5.4.13. The sort Function
- 5.4.14. The reverse Function
- 5.4.15. The unshift Function
- 5.5. Hash (Associative Array) Functions
- 5.6. More Hashes
- 5.7. What You Should Know
- 5.8. What’s Next?
-
6. Where’s the Operator?
- 6.1. About Perl Operators
- 6.2. Mixing Data Types
-
6.3. Precedence and Associativity
- 6.3.1. Assignment Operators
- 6.3.2. Relational Operators
- 6.3.3. Equality Operators
- 6.3.4. Logical Operators (Short-Circuit Operators)
- 6.3.5. Logical Word Operators
- 6.3.6. Arithmetic Operators
- 6.3.7. Autoincrement and Autodecrement Operators
- 6.3.8. Bitwise Logical Operators
- 6.3.9. Conditional Operators
- 6.3.10. Range Operator
- 6.3.11. Special String Operators and Functions
- 6.3.12. Arithmetic Functions
- 6.4. What You Should Know
- 6.5. What’s Next?
- 7. If Only, Unconditionally, Forever
- 8. Regular Expressions—Pattern Matching
- 9. Getting Control—Regular Expression Metacharacters
-
10. Getting a Handle on Files
-
10.1. The User-Defined Filehandle
- 10.1.1. Opening Files—The open Function
- 10.1.2. Open for Reading
- 10.1.3. Open for Writing
- 10.1.4. Win32 Binary Files
- 10.1.5. Open for Appending
- 10.1.6. The select Function
- 10.1.7. File Locking with flock
- 10.1.8. The seek and tell Functions
- 10.1.9. Open for Reading and Writing
- 10.1.10. Open for Pipes
- 10.2. Passing Arguments
- 10.3. File Testing
- 10.4. What You Should Know
- 10.5. What’s Next?
-
10.1. The User-Defined Filehandle
- 11. How Do Subroutines Function?
-
12. Modularize It, Package It, and Send It to the Library!
- 12.1. Packages and Modules
- 12.2. The Standard Perl Library
- 12.3. Modules from CPAN
- 12.4. What You Should Know
- 12.5. What’s Next?
-
13. Does This Job Require a Reference?
- 13.1. What Is a Reference? What Is a Pointer?
- 13.2. What You Should Know
- 13.3. What’s Next?
-
14. Bless Those Things! (Object-Oriented Perl)
- 14.1. The OOP Paradigm
- 14.2. Classes, Objects, and Methods
- 14.3. Anonymous Subroutines, Closures, and Privacy
- 14.4. Inheritance
- 14.5. Public User Interface—Documenting Classes
- 14.6. Using Objects from the Perl Library
- 14.7. What You Should Know
- 14.8. What’s Next?
- 15. Those Magic Ties and DBM Stuff
-
16. CGI and Perl: The Hyper Dynamic Duo
- 16.1. Static and Dynamic Web Pages
- 16.2. How It all Works
- 16.3. Creating a Web Page with HTML
- 16.4. How HTML and CGI Work Together
- 16.5. Getting Information Into and Out of the CGI Script
- 16.6. CGI and Forms
-
16.7. The CGI.pm Module
- 16.7.1. Introduction
- 16.7.2. Advantages
- 16.7.3. Two Styles of Programming with CGI.pm
- 16.7.4. An Important Warning!
- 16.7.5. HTML Form Methods
- 16.7.6. How CGI.pm Works with Forms
- 16.7.7. CGI.pm Form Elements
- 16.7.8. Methods Defined for Generating Form Input Fields
- 16.7.9. Error Handling
- 16.7.10. HTTP Header Methods
-
17. Perl Meets MySQL—A Perfect Connection
- 17.1. Introduction
- 17.2. What Is a Relational Database?
-
17.3. Getting Started with MySQL
- 17.3.1. Why MySQL?
- 17.3.2. Installing MySQL
- 17.3.3. Connecting to MySQL
- 17.3.4. Graphical User Tools
- 17.3.5. Finding the Databases
-
17.3.6. Getting Started with Basic Commands
- Creating a Database with MySQL
- Selecting a Database with MySQL
- Creating a Table in the Database
- Data Types
- Adding Another Table with a Primary Key
- Inserting Data into Tables
- Selecting Data from Tables—The SELECT Command
- Selecting by Columns
- Select All Columns
- The WHERE Clause
- Sorting Tables
- Joining Tables
- Deleting Rows
- Updating Data in a Table
- Altering a Table
- Dropping a Table
- Dropping a Database
-
17.4. What Is the Perl DBI?
- 17.4.1. Installing the DBI
- 17.4.2. The DBI Class Methods
- 17.4.3. How to Use DBI
- 17.4.4. Connecting to and Disconnecting from the Database
- 17.4.5. The disconnect() Method
- 17.4.6. Preparing a Statement Handle and Fetching Results
- 17.4.7. Handling Quotes
- 17.4.8. Getting Error Messages
- 17.5. Statements that Don’t Return Anything
- 17.6. Transactions
- 17.7. Using CGI and the DBI to Select and Display Entries
- 17.8. What’s Left?
- 17.9. What You Should Know
- 17.10. What’s Next?
-
18. Interfacing with the System
-
18.1. System Calls
- 18.1.1. Directories and Files
- 18.1.2. Directory and File Attributes
- 18.1.3. Finding Directories and Files
- 18.1.4. Creating a Directory—The mkdir Function
- 18.1.5. Removing a Directory—The rmdir Function
- 18.1.6. Changing Directories—The chdir Function
- 18.1.7. Accessing a Directory via the Directory Filehandle
- 18.1.8. Permissions and Ownership
- 18.1.9. Hard and Soft Links
- 18.1.10. Renaming Files
- 18.1.11. Changing Access and Modification Times
- 18.1.12. File Statistics
- 18.1.13. Low-Level File I/O
- 18.1.14. Packing and Unpacking Data
- 18.2. Processes
- 18.3. Other Ways to Interface with the Operating System
- 18.4. Error Handling
- 18.5. Signals
- 18.6. What You Should Know
- 18.7. What’s Next?
-
18.1. System Calls
- 19. Report Writing with Pictures
-
20. Send It Over the Net and Sock It to ’Em!
- 20.1. Networking and Perl
- 20.2. Client/Server Model
- 20.3. Network Protocols (TCP/IP)
- 20.4. Network Addressing
- 20.5. Sockets
- 20.6. Client/Server Programs
- 20.7. The Socket.pm Module
- 20.8. What You Should Know
- A. Perl Built-ins, Pragmas, Modules, and the Debugger
-
B. SQL Language Tutorial
- B.1. What Is SQL?
-
B.2. SQL Data Manipulation Language (DML)
-
B.2.1. The SELECT Command
- Select Specified Columns
- Select All Columns
- The SELECT DISTINCT Statement
- Limiting the Number of Lines in the Result Set with LIMIT
- The WHERE Clause
- Using Quotes
- Using the = and <> Operators
- What Is NULL?
- The > and < Operators
- The AND and OR Operators
- The LIKE and NOT LIKE Condition
- Pattern Matching and the % Wildcard
- The _ Wildcard
- The BETWEEN Statement
- Sorting Results with ORDER BY
- B.2.2. The INSERT Command
- B.2.3. The UPDATE Command
- B.2.4. The DELETE Statement
-
B.2.1. The SELECT Command
- B.3. SQL Data Definition Language
- B.4. SQL Functions
- B.5. Appendix Summary
- B.6. What You Should Know
- C. Perl and Biology
- D. Power and Speed: CGI and mod_perl
Product information
- Title: Perl by Example, Fourth Edition
- Author(s):
- Release date: November 2007
- Publisher(s): Pearson
- ISBN: 9780132381826
You might also like
book
Programming Perl, 3rd Edition
Perl is a powerful programming language that has grown in popularity since it first appeared in …
book
Learning Perl, 7th Edition
If you’re just getting started with Perl, this is the book you want—whether you’re a programmer, …
book
Programming Perl, 4th Edition
Adopted as the undisputed Perl bible soon after the first edition appeared in 1991, Programming Perl …
book
Perl Cookbook, 2nd Edition
Find a Perl programmer, and you'll find a copy of Perl Cookbook nearby. Perl Cookbook is …