Defining a Constant in PHP

Constant is important variable in any technology. When you are creating any application based on any Technology, You need to define some constant variable which will not change in throughout application.
A constant Stands for “A constant is an identifier (name) for a simple value”.

Main difference between constant and Variable

The main difference between a constant and a variable is variable may be changed but constant cannot be change in application.

Main feature of Constant

1- Constant cannot be change.
2- Define in single time and used multiple time based on requirement.
3- By default case sensitive.
4- Constant name will be in capital letter.

Continue reading …