Sorry, I know this has been covered before. Some of the questions regarding this are quite old, and I wondered why this functionality hasn't been made available as standard?
It would be really useful to be able to pass arguments to a model's constructor, along the lines of:
PHP Code:
$this->load->model('some_model', $args);
Then in the model have:
PHP Code:
public function __construct($args) {
}
I know I could make my own initialization method and do:
PHP Code:
$this->load->model('some_model');
$this->some_model->init($args);
However I have some arguments that are required for the whole model to work, and if I forget to call init() things will get somewhat messy.