-
Chapter 1 Orientation and First Steps
-
PHP's Place in the Web World
-
What's So Great About PHP?
-
PHP in Action
-
Basic Rules of PHP Programs
-
Chapter Summary
-
-
Chapter 2 Working with Text and Numbers
-
Text
-
Numbers
-
Variables
-
Chapter Summary
-
Exercises
-
-
Chapter 3 Making Decisions and Repeating Yourself
-
Understanding true and false
-
Making Decisions
-
Building Complicated Decisions
-
Repeating Yourself
-
Chapter Summary
-
Exercises
-
-
Chapter 4 Working with Arrays
-
Array Basics
-
Looping Through Arrays
-
Modifying Arrays
-
Sorting Arrays
-
Using Multidimensional Arrays
-
Chapter Summary
-
Exercises
-
-
Chapter 5 Functions
-
Declaring and Calling Functions
-
Passing Arguments to Functions
-
Returning Values from Functions
-
Understanding Variable Scope
-
Chapter Summary
-
Exercises
-
-
Chapter 6 Making Web Forms
-
Useful Server Variables
-
Accessing Form Parameters
-
Form Processing with Functions
-
Validating Data
-
Displaying Default Values
-
Putting It All Together
-
Chapter Summary
-
Exercises
-
-
Chapter 7 Storing Information with Databases
-
Organizing Data in a Database
-
Connecting to a Database Program
-
Creating a Table
-
Putting Data into the Database
-
Inserting Form Data Safely
-
Generating Unique IDs
-
A Complete Data Insertion Form
-
Retrieving Data from the Database
-
Changing the Format of Retrieved Rows
-
Retrieving Form Data Safely
-
A Complete Data Retrieval Form
-
MySQL Without PEAR DB
-
Chapter Summary
-
Exercises
-
-
Chapter 8 Remembering Users with Cookies and Sessions
-
Working with Cookies
-
Activating Sessions
-
Storing and Retrieving Information
-
Configuring Sessions
-
Login and User Identification
-
Why setcookie( ) and session_start( ) Want to Be at the Top of the Page
-
Chapter Summary
-
Exercises
-
-
Chapter 9 Handling Dates and Times
-
Displaying the Date or Time
-
Parsing a Date or Time
-
Dates and Times in Forms
-
Displaying a Calendar
-
Chapter Summary
-
Exercises
-
-
Chapter 10 Working with Files
-
Understanding File Permissions
-
Reading and Writing Entire Files
-
Reading and Writing Parts of Files
-
Working with CSV Files
-
Inspecting File Permissions
-
Checking for Errors
-
Sanitizing Externally Supplied Filenames
-
Chapter Summary
-
Exercises
-
-
Chapter 11 Parsing and Generating XML
-
Parsing an XML Document
-
Generating an XML Document
-
Chapter Summary
-
Exercises
-
-
Chapter 12 Debugging
-
Controlling Where Errors Appear
-
Fixing Parse Errors
-
Inspecting Program Data
-
Fixing Database Errors
-
Chapter Summary
-
Exercises
-
-
Chapter 13 What Else Can You Do with PHP?
-
Graphics
-
PDF
-
Shockwave/Flash
-
Browser-Specific Code
-
Sending and Receiving Mail
-
Uploading Files in Forms
-
The HTML_QuickForm Form-Handling Framework
-
Classes and Objects
-
Advanced XML Processing
-
SQLite
-
Running Shell Commands
-
Advanced Math
-
Encryption
-
Talking to Other Languages
-
IMAP, POP3, and NNTP
-
Command-Line PHP
-
PHP-GTK
-
Even More Things You Can Do with PHP
-
-
Appendix A Installing and Configuring the PHP Interpreter
-
Using PHP with a Web-Hosting Provider
-
Installing the PHP Interpreter
-
Installing PEAR
-
Downloading and Installing PHP's Friends
-
Modifying PHP Configuration Directives
-
Appendix Summary
-
-
Appendix B Regular Expression Basics
-
Characters and Metacharacters
-
Quantifiers
-
Anchors
-
Character Classes
-
Greed
-
PHP's PCRE Functions
-
Appendix Summary
-
Exercises
-
-
Appendix C Answers To Exercises
-
Chapter 2
-
Chapter 3
-
Chapter 4
-
Chapter 5
-
Chapter 6
-
Chapter 7
-
Chapter 8
-
Chapter 9
-
Chapter 10
-
Chapter 11
-
Chapter 12
-
Appendix B
-
-
Colophon
- Title:
- Learning PHP 5
- By:
- David Sklar
- Publisher:
- O'Reilly Media
- Formats:
-
- Ebook
- Safari Books Online
- Print Release:
- June 2004
- Ebook Release:
- December 2008
- Pages:
- 368
- Print ISBN:
- 978-0-596-00560-3
- | ISBN 10:
- 0-596-00560-1
- Ebook ISBN:
- 978-0-596-15970-2
- | ISBN 10:
- 0-596-15970-6
Our look is the result of reader comments, our own experimentation, and feedback from distribution channels. Distinctive covers complement our distinctive approach to technical topics, breathing personality and life into potentially dry subjects. The animal on the cover of Learning PHP 5 is an eagle. Eagles fall into the category of bird known as "raptors," a category that also includes falcons and hawks. There are two types of raptor: grasping killers, with beaks shaped for tearing and cutting and short toes with curved claws designed for killing; and grasping holders, with beaks shaped for tearing and biting, and longer toes designed for holding. Eagles are grasping killers. Sea eagles have special adaptations to their toes that enable them to grasp smooth prey such as fish. Their excellent vision enables all eagles to spot prey from the air or a high perch. The eagle then swoops down, grabs its prey, and takes off in flight again, in one graceful movement. Eagles often eat their victims while still flying, breaking them apart and discarding the nonedible parts to lighten their load. Eagles, like most raptors, often dine on sick or wounded animals.
There are more than 50 species of eagle spread throughout the world, with the exception of New Zealand and Antarctica. All species of eagles build nests, or aeries, high above the ground, in trees or on rocky ledges. Apair of eagles will use the same nest year after year, lining it with green leaves and grass, fur, turf, or soft materials. The eagle will add to its nest each year. The largest eagle nest ever found was 20 feet deep and 10 feet across.
Hunting, increased use of pesticides, and the diminishment of their natural environment, with the attendant reduction in food sources, have endangered many species of eagle. Mary Brady was the production editor and the copyeditor for Learning PHP 5. Leanne Soylemez was the proofreader. Mary Anne Weeks Mayo and Claire Cloutier provided quality control. Judy Hoer wrote the index.
Hanna Dyer designed the cover of this book, based on a series design by Edie Freedman. The cover image is a 19th-century engraving from the Dover Pictorial Archive. Emma Colby produced the cover layout with QuarkXPress 4.1 using Adobe's ITC Garamond font.
David Futato designed the interior layout. This book was converted by Joe Wizda to FrameMaker 5.5.6 with a format conversion tool created by Erik Ray, Jason McIntosh, Neil Walls, and Mike Sierra that uses Perl and XML technologies. The text font is Linotype Birka; the heading font is Adobe Myriad Condensed; and the code font is LucasFont's TheSans Mono Condensed. The illustrations that appear in the book were produced by Robert Romano and Jessamyn Read using Macromedia FreeHand 9 and Adobe Photoshop 6. The tip and warning icons were drawn by Christopher Bing. This colophon was written by Mary Brady.
