13.09.2016 Views

PHP and MySQL Web Development 4th Ed-tqw-_darksiderg

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Table of Contents<br />

Introduction 1<br />

I Using <strong>PHP</strong><br />

1 <strong>PHP</strong> Crash Course 13<br />

Before You Begin: Accessing <strong>PHP</strong> 14<br />

Creating a Sample Application: Bob’s Auto Parts 14<br />

Creating the Order Form 14<br />

Processing the Form 16<br />

Embedding <strong>PHP</strong> in HTML 17<br />

<strong>PHP</strong> Tags 18<br />

<strong>PHP</strong> Statements 19<br />

Whitespace 20<br />

Comments 20<br />

Adding Dynamic Content 21<br />

Calling Functions 22<br />

Using the date() Function 22<br />

Accessing Form Variables 23<br />

Short, Medium, <strong>and</strong> Long Variables 23<br />

String Concatenation 26<br />

Variables <strong>and</strong> Literals 27<br />

Underst<strong>and</strong>ing Identifiers 28<br />

Examining Variable Types 29<br />

<strong>PHP</strong>’s Data Types 29<br />

Type Strength 29<br />

Type Casting 30<br />

Variable Variables 30<br />

Declaring <strong>and</strong> Using Constants 31<br />

Underst<strong>and</strong>ing Variable Scope 31<br />

Using Operators 32<br />

Arithmetic Operators 33<br />

String Operators 34

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!