Welcome Guest, Not a member yet? Register   Sign In
Faster Way to Load Models and Helpers
#1

[eluser]ShoeLace1291[/eluser]
I have controllers that use the same models, helpers, and libraries in every function in that controller. Is there a way to load models, etc one time in the beginning of a controller instead of loading it in every single function in that controller? I don't want to autoload it(I already know it so don't explain it). Something like

<?php

class Page extends Controller {

$this->load->model('pagemodel');

function index(){

$this->pagemodel->page();

}

function another(){

$this->pagemodel->page();

}
}


Messages In This Thread
Faster Way to Load Models and Helpers - by El Forum - 01-09-2010, 10:26 PM
Faster Way to Load Models and Helpers - by El Forum - 01-09-2010, 10:38 PM
Faster Way to Load Models and Helpers - by El Forum - 01-10-2010, 06:29 AM



Theme © iAndrew 2016 - Forum software by © MyBB