[eluser]pistolPete[/eluser]
How about that:
Code:
function getselect($limitstart,$limitend)
{
$posts = array();
$DB1 = $this->load->database('blog', TRUE);
$DB1->select('*');
Or you can pass the database reference to the model:
Code:
// in your controller
function do_something()
{
$DB1 = $this->load->database('blog', TRUE);
$this->load->model('get_blog');
$this->get_blog->getselect(0,1,$DB1);
}
// in your model
function getselect($limitstart, $limitend, $db)
{
$posts = array();
$db->select('*');
...