BN.com Gift Guide

PHP 5 in Practice [NOOK Book]

Overview

With the release of PHP 5 web developers need a guide to developing with PHP 5 to both learn its complex new features and more fully implement the long-standing features on which PHP's success is built. PHP 5 in Practice is a reference guide that provides developers with easy-to-use and easily extensible code to solve common PHP problems. It focuses on providing real code solutions to problems, allowing the reader to learn by seeing exactly what is happening behind the scenes to get your solution. Because a ...

See more details below
PHP 5 in Practice

Available on NOOK devices and apps  
  • NOOK Devices
  • Samsung Galaxy Tab 4 NOOK 7.0
  • Samsung Galaxy Tab 4 NOOK 10.1
  • NOOK HD Tablet
  • NOOK HD+ Tablet
  • NOOK eReaders
  • NOOK Color
  • NOOK Tablet
  • Tablet/Phone
  • NOOK for Windows 8 Tablet
  • NOOK for iOS
  • NOOK for Android
  • NOOK Kids for iPad
  • PC/Mac
  • NOOK for Windows 8
  • NOOK for PC
  • NOOK for Mac

Want a NOOK? Explore Now

NOOK Book (eBook)
$19.99
BN.com price
(Save 44%)$35.99 List Price

Overview

With the release of PHP 5 web developers need a guide to developing with PHP 5 to both learn its complex new features and more fully implement the long-standing features on which PHP's success is built. PHP 5 in Practice is a reference guide that provides developers with easy-to-use and easily extensible code to solve common PHP problems. It focuses on providing real code solutions to problems, allowing the reader to learn by seeing exactly what is happening behind the scenes to get your solution. Because a real-life situation will rarely match the book's example problems precisely, PHP 5 in Practice explains the solution well enough that you will understand it and can learn how to truly solve your own problem.

Read More Show Less

Editorial Reviews

From Barnes & Noble
The Barnes & Noble Review
Want an immense library of solid, well-written PHP 5 code and application solutions? Want explanations that are clear enough you can really adapt the code to your own needs? Then you want PHP in Practice.

Section I offers scores of code solutions with broad applicability. For example, string techniques (pattern matching, eliminating white space, parsing CSV files) and numeric techniques (interest rate calculations, metric/English conversion). You’ll find chapters on manipulating times and dates; variables; arrays; functions; classes and objects; and files and directories.

Next, the authors address every major category of web application: page creation, navigation, form handling, validation, sessions, user tracking, databases, email, RSS, image generation, encryption, and more. This isn’t trivial stuff, either. Want to create a multi-layer drop-down menu? Buffer page output for server optimization? Communicate with LDAP servers? Perform database-based user authentication? Look it up, tweak it, and do it. Bill Camarda, from the August 2006 Read Only

Read More Show Less

Product Details

  • ISBN-13: 9780672332869
  • Publisher: Pearson Education
  • Publication date: 7/25/2006
  • Series: Developer's Library
  • Sold by: Barnes & Noble
  • Format: eBook
  • Edition number: 1
  • Pages: 456
  • File size: 713 KB

Meet the Author


Elliott White III has been a professional programmer since 1995. He has given various presentations at international PHP and Web conferences on topics such as PHP, CSS, and XHTML, as well as helping Brainbench develop some of their programming certifications. He currently works for Digg.com as a senior PHP programmer.

Jonathan Eisenhamer has served as systems administrator and software developer for the Astronomy department at UCLA. From there, he moved on to the Space Telescope Science Institute (STScI), where he began his work in PHP, developing websites to disseminate the scientific results from the Hubble Space Telescope to the general public. He currently is the supervisor of the Web and Print group at STScI.
Read More Show Less

Table of Contents

Introduction

Part I PHP Internals

1 Strings

1.1 Matching Patterns (Regular Expressions)

1.2 Cleaning Up Whitespace

1.3 Expanding and Compressing Tabs

1.4 Converting Text Between Macintosh, UNIX, and PC Format

1.5 Parsing CSV (Comma-Separated Values)

1.6 Truncating Text to Fit Within a Specific Space

1.7 Padding Arrays of Data to Display as Columns

1.8 Checking the Spelling of a Word

1.9 Matching Similar Strings

1.10 Performing Proper Capitalization on Titles

1.11 Generating Unique Identifiers

1.12 Counting the Number of Times Certain Words Appear

2 Numbers

2.1 Retrieving a Number from a String

2.2 Printing Proper Plural Text

2.3 Converting Numbers into Roman Numerals

2.4 Calculating Interest

2.5 Simulating Dice

2.6 Latitude/Longitude Calculations

2.7 Metric/English Conversion

2.8 Temperature Conversion

2.9 Statistics Package Creation

3 Time and Date

3.1 Calculating the Difference Between Two Dates

3.2 Determining Last Day of a Given Month

3.3 Leap Year Calculation

3.4 Handling Time Zones

3.5 Handling Time Stamps Within Databases or in Files

3.6 Determining Number of Business Days

3.7 Generating a Calendar for a Given Month

4 Variables

4.1 Determining Whether a Variable Is Equal to Another

4.2 Accessing a Variable Outside a Function, from Within it (Global Variables)

4.3 Keeping a Persistent Value Within a Function (Static Variables)

4.4 Having One Variable Refer to Another (References)

4.5 Using a Variable to Hold the Name of Another Variable

4.6 Declaring a Constant Instead of a Variable

4.7 Coalescing a List of Values to Determine the First Non-False Value

5 Arrays

5.1 Superglobal Arrays and Their Usage

5.2 Stack Implementation

5.3 Queue Implementation

5.4 Sorting with User-Defined Comparisons

5.5 Sorting with Alternative Algorithms

5.6 Recursive Handling of Multidimensional Arrays

5.7 Performing Set Operations on Arrays

5.8 Matrix Math Execution Using Arrays

6 Functions

6.1 Setting Optional Parameters

6.2 Creating Recursive Functions

6.3 Calling Functions Using a Function Name Stored in a Variable

6.4 Dynamically Creating a Function (Lambda-Style)

6.5 Using an Array of Functions for Processing

6.6 Passing or Returning a Value by Reference

6.7 Using an Arbitrary Number of Parameters

6.8 Requiring a Parameter to Be a Certain Type

7 Classes and Objects

7.1 Automatically Loading Class Source Files

7.2 Protecting Object Data (public/private/protected)

7.3 Automatically Running Code On Creation or Destruction of an Object

7.4 Accessing a Class’s Members Without Instantiation

7.5 Extending a Class Definition

7.6 Creating an Abstract Class

7.7 Using Object Interfaces

7.8 Dynamic and Overloaded Variable Names

7.9 Overloading Methods

7.10 Linked List Implementation

7.11 Binary Tree Implementation

8 Files and Directories

8.1 Generating a Full Directory Listing

8.2 Natural Display of File Sizes

8.3 Renaming All Files Within a Directory

8.4 Search for Filenames Within a Directory Tree

8.5 Handling Relative and Absolute File Paths

8.6 Reading a File Via HTTP or FTP

8.7 Watching the Contents of a File As It Grows (Simulating UNIX tail -f)

8.8 Generating a Difference Report Between Two Files

8.9 Locking a File for Exclusive Use

8.10 Caching Remote Files Locally

8.11 Compressing and Uncompressing Files

8.12 Automatically Including Certain Files from the Parent Tree

Part II Application

9 Web Page Creation/XHTML/CSS

9.1 Creating a Multilayer Drop-Down Menu

9.2 Highlighting What Section of a Website the User Is In

9.3 Displaying Dynamic Progress Bars

9.4 Simulating Graphical Charts with XHTML/CSS

9.5 Pagination of Results on a Web Page

9.6 Caching Web Page Output for Server Optimization

9.7 Localizing a Web Page for Different Languages

9.8 Using Ajax with PHP to Create an Interactive Web Page

10 Web Form Handling

10.1 Easily Obtaining Form Data

10.2 Obtaining Multidimensional Arrays of Form Data

10.3 Using GET and POST Form Data Together

10.4 Accepting Uploaded Files

10.5 Generating Select Statements

10.6 Requiring Certain Fields to Be Filled Out

10.7 Manipulating Text for Display on Bulletin Boards (BBCode)

10.8 Accepting and Displaying User Data Giving Warnings for Links

10.9 Preventing Multiple Form Submissions

11 Data Validation and Standardization

11.1 Phone Numbers

11.2 ZIP Codes

11.3 Social Security Numbers (SSNs)

11.4 Numbers

11.5 Credit Card Numbers

11.6 Dates

11.7 Email Accounts

11.8 URLs

12 Sessions and User Tracking

12.1 Using Cookies to Remember Data

12.2 Saving User Data with Sessions

12.3 Customizing Display Settings for a User

12.4 Creating a Library for Tracking a User Through Your Website

12.5 Implementing a Simple Shopping Cart

12.6 Passing Session Data Between Two Servers

12.7 Parsing Specific Browser Information from Log Files

13 Web Services and Other Protocols

13.1 Submitting a POST HTTP Request with cURL

13.2 Communicating with an LDAP Server

13.3 Using Web Services Via SOAP

13.4 Connecting to an FTP Server

13.5 Creating a PHP-Based FTP Client

13.6 Using Sockets to Connect to an Internet Server

13.7 Creating Your Own Basic Web Server

14 Relational Databases

14.1 Communicating with MySQL

14.2 Communicating with Oracle

14.3 Communicating with PostgreSQL

14.4 Communicating with Sybase

14.5 Communicating with Microsoft SQL Server

14.6 Communicating with SQLite

14.7 Communicating with Databases Through ODBC

14.8 Using an Abstraction Layer to Communicate with a Database (PDO)

14.9 Implementing an SQLite Based Blog

15 Other Data Storage Methods

15.1 Creating and Reading CSV files

15.2 Using Custom Text Files for Storage

15.3 Accessing and Updating DBM-Style Databases

15.4 Storing Data Via Serialize and Unserialize

15.5 Automatically Creating and Updating PHP Include Files

16 Email

16.1 Sending Email (Text/HTML/Dual Format/Inline Images/Attachments)

16.2 Determining Whether an Email Account Exists

16.3 Creating a Mass Email Mailer

16.4 Implementing Basic Mailing List Software

16.5 Protecting Email Addresses from Spam Collectors

16.6 Creating a Watchdog Process to Send Email If a Web Page Changes

17 XML

17.1 Parsing an XML File to Retrieve Data

17.2 Performing Searches Through XML with XPath

17.3 Validating an XML Document

17.4 Transforming XML into XHTML with XSLT

17.5 Creating an RSS File

17.6 Creating an RSS Display Script for Websites

18 Images

18.1 Generating Composite Images with Text

18.2 Drawing Tips and Tricks

18.3 Using Transparent Backgrounds in Images

18.4 Creating a Graph/Chart Library

18.5 Automatically Creating a Photo Gallery from Digital Camera Files (Exif Data)

19 Error Reporting and Debugging

19.1 Defining a Custom Error Handler

19.2 Using Exceptions to Handle Errors

19.3 Timing the Execution of Your Script

19.4 Using Shutdown Functions to Gracefully Handle Script Failures

19.5 Generating Detailed Backtracing for Error Reporting

20 User Authentication and Encryption

20.1 Generating Random Passwords

20.2 Using Encryption to Protect Data

20.3 Simple CAPTCHA for Real User Detection

20.4 Authenticating Users

Part III Appendixes

A Migrating to PHP 5

B SPL

C Common PHP Error Messages

Index

Read More Show Less

Customer Reviews

Average Rating 2
( 1 )
Rating Distribution

5 Star

(0)

4 Star

(0)

3 Star

(0)

2 Star

(1)

1 Star

(0)

Your Rating:

Your Name: Create a Pen Name or

Barnes & Noble.com Review Rules

Our reader reviews allow you to share your comments on titles you liked, or didn't, with others. By submitting an online review, you are representing to Barnes & Noble.com that all information contained in your review is original and accurate in all respects, and that the submission of such content by you and the posting of such content by Barnes & Noble.com does not and will not violate the rights of any third party. Please follow the rules below to help ensure that your review can be posted.

Reviews by Our Customers Under the Age of 13

We highly value and respect everyone's opinion concerning the titles we offer. However, we cannot allow persons under the age of 13 to have accounts at BN.com or to post customer reviews. Please see our Terms of Use for more details.

What to exclude from your review:

Please do not write about reviews, commentary, or information posted on the product page. If you see any errors in the information on the product page, please send us an email.

Reviews should not contain any of the following:

  • - HTML tags, profanity, obscenities, vulgarities, or comments that defame anyone
  • - Time-sensitive information such as tour dates, signings, lectures, etc.
  • - Single-word reviews. Other people will read your review to discover why you liked or didn't like the title. Be descriptive.
  • - Comments focusing on the author or that may ruin the ending for others
  • - Phone numbers, addresses, URLs
  • - Pricing and availability information or alternative ordering information
  • - Advertisements or commercial solicitation

Reminder:

  • - By submitting a review, you grant to Barnes & Noble.com and its sublicensees the royalty-free, perpetual, irrevocable right and license to use the review in accordance with the Barnes & Noble.com Terms of Use.
  • - Barnes & Noble.com reserves the right not to post any review -- particularly those that do not follow the terms and conditions of these Rules. Barnes & Noble.com also reserves the right to remove any review at any time without notice.
  • - See Terms of Use for other conditions and disclaimers.
Search for Products You'd Like to Recommend

Recommend other products that relate to your review. Just search for them below and share!

Create a Pen Name

Your Pen Name is your unique identity on BN.com. It will appear on the reviews you write and other website activities. Your Pen Name cannot be edited, changed or deleted once submitted.

 
Your Pen Name can be any combination of alphanumeric characters (plus - and _), and must be at least two characters long.

Continue Anonymously
Sort by: Showing 1 Customer Reviews
  • Anonymous

    Posted November 16, 2013

    small file

    All of the pages seem to be there, but the pages should be read on a larger screen than a Nook.

    Was this review helpful? Yes  No   Report this review
Sort by: Showing 1 Customer Reviews

If you find inappropriate content, please report it to Barnes & Noble
Why is this product inappropriate?
Comments (optional)