PHP Tutorials - Herong's Tutorial Examples - v5.19, by Herong Yang
Downloading and Installing PHP on macOS
This section provides a tutorial example on how to download and install the PHP engine on macOS computers.
The PHP engine is pre-installed on macOS computers. There is no need to run any command to download and install it.
For example, PHP 5.6 is available on my macOS 10.12 computer by default:
herong$ php -v PHP 5.6.30 (cli) (built: Oct 29 2017 20:30:32) Copyright (c) 1997-2016 The PHP Group Zend Engine v2.6.0, Copyright (c) 1998-2016 Zend Technologies
Table of Contents
►Introduction and Installation of PHP
Downloading and Installing PHP on Windows
Downloading and Installing PHP on Linux
►Downloading and Installing PHP on macOS
"php -help" - Command Line Options
"php -i" - PHP Engine Information
php.ini - PHP Runtime Configuration
Hello.php - My First PHP Script
"php -a" - PHP Interactive Shell
Downloading and Installing PHP Documentation
PHP Data Types and Data Literals
Variables, References, and Constants
Expressions, Operations and Type Conversions
Conditional Statements - "if" and "switch"
Loop Statements - "while", "for", and "do ... while"
Function Declaration, Arguments, and Return Values
Interface with Operating System
Introduction of Class and Object
Integrating PHP with Apache Web Server
Retrieving Information from HTTP Requests
Creating and Managing Sessions in PHP Scripts
Sending and Receiving Cookies in PHP Scripts
Controlling HTTP Response Header Lines in PHP Scripts
Functions to Manage Directories, Files and Images
Localization Overview of Web Applications
Using Non-ASCII Characters in HTML Documents
Using Non-ASCII Characters as PHP Script String Literals
Receiving Non-ASCII Characters from Input Forms
"mbstring" Extension and Non-ASCII Encoding Management
Managing Non-ASCII Character Strings with MySQL Servers
Configuring and Sending Out Emails
Managing PHP Engine and Modules on macOS