Part 6: Constant

Activity 3 Homepage

Use of Constants Example

Welcome to My Awesome Website!

The maximum number of users allowed is 100.

What are Constants?

Constants are like variables, but once they are defined, they cannot be changed or undefined. They are useful for values that should remain constant throughout the execution of a script, such as configuration settings.

Difference between Constants and Variables

Unlike variables, constants do not use the dollar sign ($) before their name. Constants are defined using the `define()` function and are automatically global across the entire script.