Viewing 1 to 2 of 2 items
Tag Archives: depreciated

Fix – Methods with the same name as their class

PHP4-style constructors still work on PHP7, they are just been deprecated and they will trigger a Deprecated warning. What you can do is define a __construct method, even an empty one, so that the php4-constructor method won’t be called on a newly-created instance of the class. Change to:

0