illustrate
1. Variables in PHP refer to the amount that the value used in the program can change, and the opposite is a constant.
2. After the constant value is defined, it cannot be changed anywhere else in the script.
Format
define ( string $name , mixed $value , bool $case_insensitive = false )
$name: regular name.
$value: constant value; in PHP5, value must be a standard value (int, float, string, boolean, null), or it can be an array value in PHP7.
$case_insensitive: If set to true, the case is not sensitive. By default, case is sensitive. PHP7.3.0 deprecated the definition of case-insensitive constants.
Return value: true on success, false on failure.
Example
Allowed to be array
define('People', array( 'man', 'woman', 'strick' )); echo People[1]; ?> 1
Output: woman
The above is how to define constants in PHP. I hope it will be helpful to everyone.