- error_reporting: documentation ( source)
<?php
error_reporting(E_ERROR | E_WARNING | E_PARSE);
class Class1 {
var $testVar = 5;
function foo(){
echo $this->foo2();
}
function foo2(){
}
}
class Class2 {
function __construct(){
$this->class1 = new Class1();
}
function bar(){
//This doesn't report an error because error level 'strict' is disabled.
Class1::foo();
}
}
$class2 = new Class2();
$class2->bar();
?>