The "constructor" is the __construct() method, and it gets executed
automatically when you instantiate the class into an object. The class
defines the state (fields/properties) and behavior (methods/functions) that
its objects will have. Instantiating the class is the fancy term for
creating a new object with that state and behavior and calling the class's
constructor on it. From then on you can call other methods on the object and
access its public state.

David

Reply via email to