Only variables should be assigned by reference
This error is not an exclusive version of PHP 7, you will also get it in older versions. Anyway, I think the problem here is is_loaded() , and it does not return the link correctly. Does it return by reference (it's like function &is_loaded() )? If not, it is necessary. Does it return a variable or expression? If this is not a variable, you need to put it in one before you can return a link to it.
PHP man page for this error: http://php.net/manual/en/language.references.return.php
Methods with the same name as their class will not be constructors in a future version of PHP; CI_DB_driver has an obsolete constructor
In PHP 4, you created a constructor method, calling it the same as a class. Therefore, if your class was class FooBar , your constructor would be a public function FooBar . However, in PHP 5 and above, the recommended name for the __construct constructor is. So go ahead and edit this class and rename its constructor to get rid of obsolescence errors. Be sure to look at any expandable classes to see if they call this constructor method, so you can change them.
See update guide: http://php.net/manual/en/migration70.deprecated.php
Also see RFC: https://wiki.php.net/rfc/remove_php4_constructors
source share