Muutke küpsiste eelistusi

Sams Teach Yourself PHP in 24 Hours 3rd edition [Pehme köide]

  • Formaat: Paperback / softback, 576 pages, kõrgus x laius x paksus: 230x191x29 mm, kaal: 948 g
  • Ilmumisaeg: 24-Dec-2003
  • Kirjastus: Sams Publishing
  • ISBN-10: 0672326191
  • ISBN-13: 9780672326196
Teised raamatud teemal:
  • Pehme köide
  • Hind: 49,81 €*
  • * saadame teile pakkumise kasutatud raamatule, mille hind võib erineda kodulehel olevast hinnast
  • See raamat on trükist otsas, kuid me saadame teile pakkumise kasutatud raamatule.
  • Kogus:
  • Lisa ostukorvi
  • Tasuta tarne
  • Lisa soovinimekirja
  • Formaat: Paperback / softback, 576 pages, kõrgus x laius x paksus: 230x191x29 mm, kaal: 948 g
  • Ilmumisaeg: 24-Dec-2003
  • Kirjastus: Sams Publishing
  • ISBN-10: 0672326191
  • ISBN-13: 9780672326196
Teised raamatud teemal:
Zandstra, a Web designer, offers step-by-step instructions for using PHP, a popular Web scripting language. Coverage progresses from first principles to a working knowledge of the PHP programming language, with chapters covering basic features of the language, functions and techniques, and library code. Chapter quizes and exercises are included. An understanding of the Web and of HTML is assumed, and some of the examples are written to work with SQL databases. Although no prior knowledge of programming is required, some experience with a language such as C or Perl is helpful. Annotation ©2004 Book News, Inc., Portland, OR (booknews.com)

Think of all the things you could do in 24 hours. Go sightseeing. Read a book. Learn PHP. Sams Teach Yourself PHP in 24 Hours is a unique learning tool that is divided into 24 one-hour lessons over five sections. Starting with the basics, you will discover the fundamentals of PHP and how to apply that knowledge to create dynamic websites with forms, cookies and authentication functions. You will also find out how to access databases, as well as how to integrate system components, e-mail, LDAP, network sockets and more. A support website includes access to source code, PHP updates, errata and links to other relevant websites. Sams Teach Yourself PHP in 24 Hours is a quick and easy way to learn how to create interactive websites for your end user.

Muu info

Think of all the things you could do in 24 hours. Go sightseeing. Read a book. Learn PHP. Sams Teach Yourself PHP in 24 Hours is a unique learning tool that is divided into 24 one-hour lessons over five sections. Starting with the basics, you will discover the fundamentals of PHP and how to apply that knowledge to create dynamic websites with forms, cookies and authentication functions. You will also find out how to access databases, as well as how to integrate system components, e-mail, LDAP, network sockets and more. A support website includes access to source code, PHP updates, errata and links to other relevant websites. Sams Teach Yourself PHP in 24 Hours is a quick and easy way to learn how to create interactive websites for your end user.
Introduction 1(7)
Part I: Getting Started
PHP: From Home Page to Web Enterprise
7(6)
What Is PHP?
7(1)
What Need Does PHP Fulfill?
8(1)
What's New in PHP 5
9(1)
The Zend Engine
9(1)
Why Choose PHP?
10(1)
Speed of Development
10(1)
PHP Is Open Source
10(1)
Performance
11(1)
Portability
11(1)
What's New in This Edition
11(1)
Summary
11(1)
Q&A
12(1)
Workshop
12(1)
Quiz
12(1)
Answers
12(1)
Exercise
12(1)
Installing PHP
13(14)
Platforms, Servers, Databases, and PHP
13(1)
Where to Find PHP and More
14(1)
Installing PHP for Linux and Apache
14(3)
Some configure Options
17(2)
- -with - gdbm
17(1)
- -with - gd
17(1)
- -with - freetype
18(1)
- -with - mysql
18(1)
- -with - xslt
19(1)
Configuring Apache
19(1)
php.ini
20(2)
short_open_tag
21(1)
Error Reporting Directives
21(1)
Variable Directives
22(1)
Changing php.ini Directives Locally
22(1)
Help!
22(2)
Summary
24(1)
Q&A
24(1)
Workshop
25(1)
Quiz
25(1)
Answers
25(1)
Exercise
25(2)
A First Script
27(14)
Our First Script
27(6)
Beginning and Ending a Block of PHP Statements
30(2)
The print() Function
32(1)
Combining HTML and PHP
33(2)
Adding Comments to PHP Code
35(1)
Summary
35(1)
Q&A
36(1)
Workshop
36(1)
Quiz
36(1)
Answers
37(1)
Exercise
37(4)
Part II: The Language
The Building Blocks
41(22)
Variables
41(2)
Data Types
43(7)
Displaying Type Information with var_dump ()
46(1)
Testing for a Specific Data Type
46(1)
Changing Type with settype ()
47(1)
Changing Type by Casting
48(1)
More Ways of Changing Type
49(1)
Why Test Type?
50(1)
Operators and Expressions
50(7)
The Assignment Operator
51(1)
Arithmetic Operators
51(1)
The Concatenation Operator
52(1)
Combined Assignment Operators
52(1)
Comparison Operators
53(1)
Creating More Complex Test Expressions with the Logical Operators
54(1)
Automatically Incrementing and Decrementing an Integer Variable
55(1)
Operator Precedence
56(1)
Constants
57(2)
Predefined Constants
59(1)
Summary
59(1)
Q&A
59(1)
Workshop
60(1)
Quiz
60(1)
Answers
61(1)
Exercises
61(2)
Going with the Flow
63(20)
Switching Flow
63(7)
The if Statement
64(1)
Using the else Clause with the if Statement
65(1)
Using the else if Clause with the if Statement
66(1)
The switch Statement
67(2)
Using the? Operator
69(1)
Loops
70(7)
The while Statement
70(1)
The do . . . while Statement
71(1)
The for Statement
72(1)
Breaking Out of Loops with the break Statement
73(2)
Skipping an Iteration with the continue Statement
75(1)
Nesting Loops
76(1)
Code Blocks and Browser Output
77(2)
Summary
79(1)
Q&A
79(1)
Workshop
80(1)
Quiz
80(1)
Answers
80(1)
Exercises
81(2)
Functions
83(24)
What Is a Function?
83(1)
Calling Functions
84(1)
Defining a Function
85(2)
Returning Values from User-Defined Functions
87(1)
Dynamic Function Calls
88(1)
Variable Scope
89(4)
Accessing Variables with the global Statement
91(2)
Saving State Between Function Calls with the static Statement
93(3)
More About Arguments
96(4)
Setting Default Values for Arguments
96(2)
Passing References to Variables to Functions
98(1)
Returning References from Functions
99(1)
Creating Anonymous Functions
100(1)
Testing for Function Existence
101(2)
Summary
103(1)
Q&A
103(1)
Workshop
104(1)
Quiz
104(1)
Answers
105(1)
Exercise
105(2)
Arrays
107(22)
What Is an Array?
107(1)
Creating Arrays
108(2)
Defining Arrays with the array () Construct
108(1)
Defining or Adding to Arrays with the Array Identifier
109(1)
Populating an Array with array_fill ()
110(1)
Associative Arrays
110(1)
Defining Associative Arrays with the array () Construct
110(1)
Directly Defining or Adding to an Associative Array
111(1)
Multidimensional Arrays
111(2)
Accessing Arrays
113(6)
Getting the Size of an Array
113(1)
Looping Through an Array
114(1)
Looping Through an Associative Array
115(1)
Outputting a Multidimensional Array
116(2)
Examining Arrays with print_r ()
118(1)
Manipulating Arrays
119(4)
Joining Two Arrays with array_merge ()
120(1)
Adding Multiple Variables to an Array
120(1)
Removing the First Element of an Array with array_shift ()
121(1)
Slicing Arrays with array_slice ()
122(1)
Sorting Arrays
123(2)
Sorting Numerically Indexed Arrays with sort ()
123(1)
Sorting an Associative Array by Value with asort ()
123(1)
Sorting an Associative Array by Key with ksort ()
124(1)
Functions Revisited
125(1)
Summary
126(1)
Q&A
127(1)
Workshop
127(1)
Quiz
127(1)
Answers
128(1)
Exercises
128(1)
Working with Strings
129(26)
Formatting Strings
129(9)
Working with printf ()
129(4)
Specifying a Field Width
133(4)
Argument Swapping
137(1)
Storing a Formatted String
138(1)
Investigating Strings
138(4)
A Note About Indexing Strings
138(1)
Finding the Length of a String with strlen ()
138(1)
Finding a Substring Within a String with strstr ()
139(1)
Finding the Position of a Substring with strpos ()
139(1)
Extracting Part of a String with substr ()
140(1)
Tokenizing a String with strtok ()
140(2)
Manipulating Strings
142(9)
Cleaning Up a String with trim (), ltrim (), and strip_tags ()
142(1)
Replacing a Portion of a String Using substr_replace ()
143(1)
Replacing Substring Using str_replace ()
144(1)
Converting Case
145(1)
Wrapping Text with wordwrap () and n12br ()
146(1)
Breaking Strings into Arrays with explode ()
147(1)
Formatting Numbers As Text
147(4)
Summary
151(1)
Q&A
152(1)
Workshop
152(1)
Quiz
152(1)
Answers
153(1)
Exercises
153(2)
Objects
155(26)
What Is an Object?
155(1)
Creating an Object
156(1)
Object Properties
157(1)
Object Methods
158(3)
Object Constructors
159(2)
Limiting Access to Object Properties
161(2)
Limiting Access to Object Methods
163(1)
Constraining Arguments to Methods with Hints
164(2)
Inheritance
166(4)
Overriding the Method of a Parent Class
167(1)
Calling an Overridden Method
168(1)
Working with Constructors
169(1)
Testing Classes and Objects
170(2)
Finding the Class of an Object
170(1)
Finding the Family of an Object
171(1)
Checking for Class and Method Existence
172(1)
Automatically Loading Include Files with_autoload ()
172(1)
Storing and Retrieving Objects
173(1)
Summary
174(1)
Q&A
175(1)
Workshop
175(3)
Quiz
175(1)
Answers
176(2)
Exercises
178(3)
Part III: Working with PHP
Working with Forms
181(22)
Superglobal Variables
181(1)
The $_SERVER Array
182(2)
A Script to Acquire User Input
184(2)
Importing User Input into Global Scope
186(1)
Accessing Form Input with User-Defined Arrays
186(2)
Combining HTML and PHP Code on a Single Page
188(3)
Using Hidden Fields to Save State
191(2)
Redirecting the User
193(2)
File Upload Forms and Scripts
195(4)
Summary
199(1)
Q&A
199(1)
Workshop
199(2)
Quiz
199(1)
Answers
200(1)
Exercises
201(2)
Working with Files
203(24)
Including Files with include ()
203(4)
Returning a Value from an Included Document
205(1)
Using include () Within Control Structures
206(1)
include_once ()
207(1)
Using include_once () and include_path to Manage Larger Projects
207(2)
Testing Files
209(4)
Checking for Existence with file_exists ()
209(1)
A File or a Directory?
209(1)
Checking the Status of a File
210(1)
Determining File Size with filesize ()
210(1)
Getting Date Information About a File
210(1)
Creating a Function That Performs Multiple File Tests
211(2)
Creating and Deleting Files
213(1)
Opening a File for Writing, Reading, or Appending
213(1)
Reading from Files
214(4)
Reading Lines from a File with fgets () and feof ()
214(2)
Reading Arbitrary Amounts of Data from a File with fread ()
216(1)
Reading Characters from a File with fgetc ()
217(1)
Reading the Contents of a File with file_get_contents ()
218(1)
Writing or Appending to a File
218(1)
Writing to a File with fwrite () or fputs ()
219(1)
Writing Data to a File with file_put_contents ()
219(2)
Locking Files with flock ()
220(1)
Working with Directories
221(2)
Creating Directories with mkdir ()
221(1)
Removing a Directory with rmdir ()
221(1)
Opening a Directory for Reading with opendir ()
221(1)
Reading the Contents of a Directory with readdir ()
222(1)
Summary
223(1)
Q&A
223(1)
Workshop
224(1)
Quiz
224(1)
Answers
225(1)
Exercises
225(2)
Working with the DBA Functions
227(18)
Beneath the Abstraction
227(2)
Opening a Database
229(1)
Adding Data to the Database
230(1)
Amending Elements in a Database
231(1)
Reading from a Database
231(3)
Determining Whether an Item Exists in a Database
234(1)
Deleting an Item from a Database
234(1)
Adding Complex Data Structures to a Database
234(4)
An Example
238(5)
Summary
243(1)
Q&A
243(1)
Workshop
244(1)
Quiz
244(1)
Answers
244(1)
Exercises
244(1)
Database Integration---SQL
245(26)
A (Very) Brief Introduction to SQL
245(2)
Connecting to the MySQL Database Server
247(1)
Selecting a Database
248(1)
Finding Out About Errors
249(1)
Adding Data to a Table
250(3)
Acquiring the Value of an Automatically Incremented Field
253(1)
Accessing Information
254(4)
Finding the Number of Rows Found by a Query
254(1)
Accessing a Resultset
255(3)
Changing Data
258(2)
SQLite: A Lightweight SQL Engine
260(2)
Creating a Table in a SQLite Database
260(1)
Entering and Updating Data
261(1)
Selecting Data
262(1)
Using the PEAR DB Package
262(6)
Installing the PEAR::DB Package
263(1)
Working with the PEAR::DB Package
263(5)
Summary
268(1)
Q&A
268(1)
Workshop
269(1)
Quiz
269(1)
Answers
269(1)
Exercises
270(1)
Beyond the Box
271(24)
Server Variables Revisited
271(3)
A Brief Summary of an HTTP Client/Server Negotiation
274(4)
The Request
274(2)
The Response
276(2)
Getting a Document from a Remote Address
278(1)
Converting IP Addresses and Hostnames
279(1)
Making a Network Connection
280(6)
Making an NNTP Connection Using fsockopen ()
284(2)
Sending Mail with the mail () Function
286(1)
An Introduction to Streams
287(4)
Streams and Contexts
288(3)
Summary
291(1)
Q&A
291(1)
Workshop
292(1)
Quiz
292(1)
Answers
292(1)
Exercises
293(2)
Images On-the-Fly
295(26)
Checking Your Configuration with gd_info ()
295(2)
Creating and Outputting Images
297(1)
Acquiring Color
297(2)
Drawing Lines
299(2)
Applying Color Fills
301(1)
Drawing an Arc
302(1)
Drawing a Rectangle
303(1)
Drawing a Polygon
304(1)
Making a Color Transparent
305(1)
Working with Text
306(7)
Writing to an Image with the imagestring () Function
306(1)
Working with TrueType Fonts
307(1)
Writing a String with imageTTFtext ()
308(1)
Testing Text Dimensions with imageTTFbox ()
309(4)
Bringing It Together
313(5)
Summary
318(1)
Q&A
319(1)
Workshop
319(1)
Quiz
319(1)
Answers
319(1)
Exercises
320(1)
Working with Dates and Times
321(22)
Getting the Date with time ()
321(1)
Converting a Timestamp with getdate ()
322(2)
Converting a Timestamp with date ()
324(2)
Creating Timestamps with mktime ()
326(1)
Testing a Date with checkdate ()
327(1)
An Example
327(7)
The DateIterator Class
327(2)
The QuickCalendar Class
329(2)
The DateViewHelper Class
331(1)
The Client Code
332(2)
A Date Pull-down Library
334(6)
Summary
340(1)
Q&A
340(1)
Workshop
341(1)
Quiz
341(1)
Answers
341(1)
Exercise
341(2)
Advanced Objects
343(26)
Objects and Constants
343(2)
Static Properties
345(1)
Static Methods
346(2)
Intercepting Calls to Object Properties and Methods
348(4)
Final Methods
352(1)
Cleaning Up Using Destructors
352(2)
Managing Error Conditions with Exceptions
354(3)
Defining Custom Exception Classes
355(2)
Tools for Building Object Hierarchies
357(7)
Abstract Classes
358(3)
Interfaces
361(3)
Passing and Assigning Objects
364(1)
Summary
365(1)
Q&A
365(1)
Workshop
366(1)
Quiz
366(1)
Answers
366(1)
Exercises
367(2)
Working with Regular Expressions
369(20)
Perl Compatible Regular Expressions
369(17)
Matching Patterns with preg_match ()
370(7)
Finding Matches Globally with preg_match_all ()
377(3)
Using preg_replace () to Replace Patterns
380(1)
Modifiers
381(3)
Using preg_replace_callback () to Replace Patterns
384(1)
Using preg_split () to Break Up Strings
385(1)
Summary
386(1)
Q&A
386(1)
Workshop
386(2)
Quiz
386(1)
Answers
387(1)
Exercise
388(1)
Saving State with Cookies and Query Strings
389(16)
Cookies
389(2)
The Anatomy of a Cookie
390(1)
Setting a Cookie with PHP
391(10)
Deleting a Cookie
393(1)
Creating Session Cookies
393(1)
An Example---Tracking Site Usage
393(8)
Working with the Query String
401(1)
Creating a Query String
401(2)
Summary
403(1)
Q&A
403(1)
Workshop
404(1)
Quiz
404(1)
Answers
404(1)
Exercises
404(1)
Saving State with Session Functions
405(12)
What Are Session Functions?
405(1)
Starting a Session with session_start ()
406(1)
Working with Session Variables
407(5)
Destroying Sessions and Unsetting Elements
412(1)
Passing Session IDs in the Query String
413(1)
Encoding and Decoding Session Variables
413(1)
Summary
414(1)
Q&A
415(1)
Workshop
415(1)
Quiz
415(1)
Answers
416(1)
Exercises
416(1)
Working with the Server Environment
417(16)
Opening Pipes to and from Processes with popen () and proc_open ()
417(7)
Running Commands with exec ()
424(1)
Running External Commands with system () or the Backtick Operator
425(1)
Plugging Security Holes with escapeshellcmd ()
426(3)
Running External Applications with passthru ()
429(1)
Calling an External CGI Script with the virtual () Function
430(1)
Summary
430(1)
Q&A
431(1)
Workshop
431(1)
Quiz
431(1)
Answers
432(1)
Exercises
432(1)
XML
433(26)
What Is XML?
433(3)
XML Parser Functions
436(7)
Acquiring a Parser Resource
436(1)
Setting XML Handlers
437(1)
xml_parser_set_option ()
438(1)
Parsing the Document
439(1)
Reporting Errors
439(2)
An Example
441(2)
An Introduction to the DOM XML Functions
443(8)
Acquiring a DomDocument Object
444(1)
The Root Element
444(1)
Adding New DomElement Objects to the Tree
445(2)
Getting Information from DomElement Objects
447(1)
Examining Text Nodes
448(1)
Traversing a Tree: Two Approaches
449(2)
XSL: A Brief Discussion
451(2)
PHP and XSL
451(1)
An XSL Document
451(2)
Applying XSL to XML with PHP
453(1)
Introducing SimpleXML
453(1)
Summary
454(1)
Q&A
455(1)
Workshop
455(1)
Quiz
455(1)
Answers
456(1)
Exercises
456(3)
Part IV: Extending PHP
PEAR: Reusable Components to Extend the Power of PHP
459(26)
What Is PEAR?
459(2)
Installing PEAR
460(1)
PEAR and Packages
460(1)
Installing a Package
461(1)
Some PEAR Packages in Action
461(19)
The Auth Package
461(8)
The PhpDocumentor Package
469(6)
Editing Configuration Files with the Config Package
475(5)
PEAR and Your Own Code
480(1)
Coding Standards
480(1)
Summary
481(1)
Q&A
482(1)
Workshop
482(1)
Quiz
482(1)
Answers
483(1)
Exercises
483(2)
Toward a Framework for Larger Projects
485(30)
Principles and Problems
485(2)
The Controller Object
487(2)
The RequestHelper and DataStore Classes
489(4)
The CommandFactory Class
493(3)
The Command Class
496(1)
The Dispatcher Class
497(4)
Working with the Framework
501(10)
Implementing ApplicationResources
502(2)
The TaskFacade Object
504(2)
The Command Classes
506(2)
The Views
508(3)
Where Now, and Was It Worth It?
511(1)
Summary
512(1)
Q&A
513(1)
Workshop
513(1)
Quiz
513(1)
Answers
514(1)
Exercises
514(1)
Glossary 515(10)
Index 525


Matt Zandstra is a writer and consultant specializing in server programming. With his business partner, Max Guglielmino, he runs Corrosive (http://www.corrosive.co.uk), a technical agency that plans, designs and builds Internet applications. Matt is interested in all aspects of object-oriented programming and is currently exploring enterprise design patterns for PHP 5. When he is not reading, writing or thinking about coding in PHP and Java, Matt shoots alien invaders in the park with his four-year-old daughter Holly. He lives by the sea in Brighton, Great Britain, with his partner Louise McDougall and their children Holly and Jake.