- Foreword....................................................................................................................
- Preface........................................................................................................................
- Acknowledgments..................................................................................................
- Part I: PROGRAMMING WITH PHP...................................................................
- Chapter 1. AN INTRODUCTION TO PHP........................................................
- The Origins of PHP.............................................................................................
- What Makes PHP Better than Its Alternatives........................................
- Interfaces to External Systems....................................................................
- How PHP Works with the Web Server........................................................
- Hardware and Software Requirements......................................................
- Installation on Apache for UNIX...................................................................
- Installation on IIS for Windows NT.............................................................
- Editing Scripts......................................................................................................
- Algorithms.............................................................................................................
- What a PHP Script Looks Like.......................................................................
- Saving Data for Later.......................................................................................
- Receiving User Input.........................................................................................
- Choosing between Alternatives....................................................................
- Repeating Code...................................................................................................
- Conclusion.............................................................................................................
- Chapter 2. VARIABLES, OPERATORS, AND EXPRESSIONS...................
- Identifiers..............................................................................................................
- Data Types............................................................................................................
- Variable Creation and Scope..........................................................................
- Assigning Values to Variables........................................................................
- Retrieving Values...............................................................................................
- Freeing Memory..................................................................................................
- Constants...............................................................................................................
- Operators...............................................................................................................
- Logical and Relational Operators.................................................................
- Bitwise Operators...............................................................................................
- Miscellaneous Operators..................................................................................
- Assignment Operators......................................................................................
- Expressions...........................................................................................................
- Chapter 3. CONTROL STATEMENTS................................................................
- True and False.....................................................................................................
- The if Statement..............................................................................................
- The? Operator....................................................................................................
- The switch Statement.....................................................................................
- Loops.......................................................................................................................
- The while Statement.......................................................................................
- The break Statement.......................................................................................
- The continue Statement................................................................................
- The do...while Statement...........................................................................
- The for Statement............................................................................................
- The foreach Statement..................................................................................
- exit, die, and return.....................................................................................
- Evaluation of Boolean Expressions..............................................................
- Chapter 4. FUNCTIONS........................................................................................
- Declaring a Function.........................................................................................
- The return Statement.....................................................................................
- Scope and the global Statement...............................................................
- Arguments.............................................................................................................
- Recursion...............................................................................................................
- Dynamic Function Calls....................................................................................
- Chapter 5. ARRAYS................................................................................................
- Single-Dimensional Arrays.............................................................................
- Indexing Arrays...................................................................................................
- Initializing Arrays...............................................................................................
- Multidimensional Arrays..................................................................................
- Casting Arrays.....................................................................................................
- Referencing Arrays Inside Strings...............................................................
- Chapter 6. CLASSES AND OBJECTS.............................................................
- Defining a Class................................................................................................
- Creating an Object...........................................................................................
- Accessing Properties and Methods............................................................
- Chapter 7. I/O AND DISK ACCESS................................................................
- HTTP Connections............................................................................................
- Writing to the Browser...................................................................................
- Output Buffering...............................................................................................
- Environment Variables...................................................................................
- Getting Input from Forms.............................................................................
- Cookies.................................................................................................................
- File Uploads........................................................................................................
- PUT Method Requests.....................................................................................
- Reading and Writing to Files........................................................................
- Sessions...............................................................................................................
- The include and require Functions.......................................................
- Part II: FUNCTIONAL REFERENCE.................................................................
- Chapter 8. I/O FUNCTIONS..............................................................................
- Sending Text to the Browser.......................................................................
- Output Buffering...............................................................................................
- Files........................................................................................................................
- Compressed File Functions...........................................................................
- POSIX....................................................................................................................
- Debugging...........................................................................................................
- Session Handling..............................................................................................
- Shell Commands...............................................................................................
- HTTP Headers....................................................................................................
- Network I/O........................................................................................................
- FTP.........................................................................................................................
- Chapter 9. DATA FUNCTIONS.........................................................................
- Data Types, Constants, and Variables.....................................................
- Arrays....................................................................................................................
- Hashing................................................................................................................
- Strings..................................................................................................................
- Encoding and Decoding.................................................................................
- Encryption...........................................................................................................
- Regular Expressions........................................................................................
- Perl-Compatible Regular Expressions......................................................
- Chapter 10. MATHEMATICAL FUNCTIONS..................................................
- Common Math...................................................................................................
- Random Numbers............................................................................................
- Arbitrary-Precision Numbers........................................................................
- Chapter 11. TIME, DATE, AND CONFIGURATION FUNCTIONS..........
- Time and Date...................................................................................................
- Alternative Calendars.....................................................................................
- Configuration.....................................................................................................
- Chapter 12. IMAGE FUNCTIONS....................................................................
- Analyzing Images.............................................................................................
- Creating JPEG, PNG, and WBMP Images................................................
- Chapter 13. DATABASE FUNCTIONS............................................................
- dBase....................................................................................................................
- DBM-style Database Abstraction................................................................
- filePro....................................................................................................................
- Informix...............................................................................................................
- InterBase.............................................................................................................
- mSQL.....................................................................................................................
- ODBC.....................................................................................................................
- Oracle....................................................................................................................
- Postgres...............................................................................................................
- Sybase..................................................................................................................
- Chapter 14. MISCELLANEOUS FUNCTIONS...............................................
- Apache..................................................................................................................
- Aspell.....................................................................................................................
- COM.......................................................................................................................
- Gettext..................................................................................................................
- IMAP......................................................................................................................
- Java........................................................................................................................
- LDAP......................................................................................................................
- Semaphores.......................................................................................................
- Shared Memory.................................................................................................
- SNMP.....................................................................................................................
- WDDX....................................................................................................................
- XML........................................................................................................................
- Part III: ALGORITHMS.......................................................................................
- Chapter 15. SORTING, SEARCHING, AND RANDOM NUMBERS........
- Sorting..................................................................................................................
- Bubble Sort.........................................................................................................
- Quicksort.............................................................................................................
- Built-In Sorting Functions.............................................................................
- Sorting with a Comparison Function.........................................................
- Searching.............................................................................................................
- Indexing...............................................................................................................
- Random Numbers............................................................................................
- Random Identifiers..........................................................................................
- Choosing Banner Ads......................................................................................
- Chapter 16. PARSING AND STRING EVALUATION..................................
- Tokenizing...........................................................................................................
- Regular Expressions........................................................................................
- Defining Regular Expressions......................................................................
- Using Regular Expressions in PHP Scripts..............................................
- Chapter 17. DATABASE INTEGRATION........................................................
- Building HTML Tables from SQL Queries.................................................
- Tracking Visitors with Session Identifiers...............................................
- Storing Content in a Database....................................................................
- Database Abstraction Layers.......................................................................
- Chapter 18. NETWORK.......................................................................................
- HTTP Authentication........................................................................................
- Controlling Browser Cache...........................................................................
- Setting Document Type.................................................................................
- Email with Attachments.................................................................................
- Verifying an Email Address...........................................................................
- Chapter 19. GENERATING GRAPHICS..........................................................
- Dynamic Buttons..............................................................................................
- Generating Graphs on the Fly.....................................................................
- Bar Graphs..........................................................................................................
- Pie Charts............................................................................................................
- Stretching Single-Pixel Images...................................................................
- Part IV: SOFTWARE ENGINEERING..............................................................
- Chapter 20. INTEGRATION WITH HTML......................................................
- Sprinkling PHP within an HTML Document.............................................
- Using PHP to Output All HTML.....................................................................
- Separating HTML from PHP..........................................................................
- Creating
- Passing Arrays in Forms................................................................................
- Chapter 21. DESIGN...........................................................................................
- Writing Requirements Specifications........................................................
- Writing Design Documents...........................................................................
- Using CVS............................................................................................................
- Modularization Using include.....................................................................
- FreeEnergy..........................................................................................................
- FastTemplate.....................................................................................................
- Midgard................................................................................................................
- Ariadne.................................................................................................................
- Preserving State and Providing Security.................................................
- Cloaking...............................................................................................................
- URLs Friendly to Search Engines...............................................................
- Running a Script Regularly...........................................................................
- Chapter 22. EFFICIENCY AND DEBUGGING..............................................
- Measuring Performance.................................................................................
- Fetching Database Query Results..............................................................
- When to Store Content in a Database.....................................................
- In-Line Debugging...........................................................................................
- Remote Debugging..........................................................................................
- Simulating HTTP Connections.....................................................................
- Appendix A. BACKSLASH CODES...................................................................
- Appendix B. ASCII CODES................................................................................
- Appendix C. OPERATORS..................................................................................
- Appendix D. PHP TAGS......................................................................................
- Appendix E. PHP COMPILE-TIME CONFIGURATION................................
- Appendix F. INTERNET RESOURCES.............................................................
- Portals...................................................................................................................
- Software...............................................................................................................
- Jobs and Services.............................................................................................
- Appendix G. PHP STYLE GUIDE......................................................................
- Comments...........................................................................................................
- Function Declarations.....................................................................................
- Compound Statements..................................................................................
- Naming.................................................................................................................
- Expressions.........................................................................................................
singke
(singke)
#1