[eluser]kaege[/eluser]
I have this code in my controller:
Code:
$a=array('name'=>'customer');
$this->load->library('ais_form', $a);
And this is how my library look like:
Code:
class Ais_form {
protected $CodeIgniter;
private $name;
private $elements;
public function __construct($a=array('name'=>'Tri')) {
$this->name = $a['name'];echo $this->name;
I clearly have supplied library Ais_form with variable $a in the controller. So, $this->name value in the library should be 'customer', but, when I echoed that $this->name, what was displayed was 'Tri' (the initial value). Is there something wrong in my code or is this a bug in CI?
And besides, what was the structure of config file supplying arguments for library? I can't seem to find it in CI user guide or any other CI resource.