This works for me:
class father {
var $user;
function __construct() {
add_action( 'init', array( &$this, 'set_user' ) );
}
function set_user() {
$this->user = wp_get_current_user();
}
}
class child extends father {
function __construct() {
parent::__construct();
}
function user_id(){
return $this->user->ID;
}
}
$father = new father();
$child = new child();
add_action( 'admin_notices', 'test_stuff' );
function test_stuff() {
global $child;
print '<pre>Child: ' . print_r( $child->user_id(), true ) . '</pre>';
}