Using Construct To Automatically Initiate Specific Functions Using Only The New Class Call !
public function __construct()
}//end function construct//
public function doSomething()
echo 'Construct Auto Initiates our doSomething function.';
}//end function doSomething//
$example = new Example; //we call our class//
//$example->doSomething(); //now using contruct We Do Not Need This Line.//
The construct function executes our doSomething function Automatically.
The example above will be very useful when creating a database connection class or as a refined way to pass class functions to other classes similar to Framework Development.