A = new A(); } function B1() { return A::A1(); } function B2() { return A::A2(); } } $B = new B(); echo $B->B1(); echo $B->B2(); ?>