First of all, I want to write two class.
<?php
class A
{
function load($v)
{
$this->$v = "stack";
}
}
class Base
{
var $lib = null;
function __construct()
{
$this->lib = new A();
}
}
$bs = new Base();
$bs->lib->load("libx");
// Current calling method
$bs->lib->libx;
// But I want this
$bs->libx;
?>
I write a MVC fremawork. CodeIgniter can do this but I could not. My english is poor. Because of this, don't talk me complicated please.