Welcome Guest, Not a member yet? Register   Sign In
MY_MODEL
#4

[eluser]johnpeace[/eluser]
No, it would actually be:

Code:
class Things extends MY_Model {
    // automatically set to plural form of your model name...in this case, 'thingss'

    var $_table = 'things';

    public function __construct() {
        parent::__construct();
    }

}

Then, to use it:

Code:
$this->load->model('things');

$this->things->get_all();


Messages In This Thread
MY_MODEL - by El Forum - 11-26-2012, 12:16 PM
MY_MODEL - by El Forum - 11-26-2012, 12:33 PM
MY_MODEL - by El Forum - 11-26-2012, 12:47 PM
MY_MODEL - by El Forum - 11-26-2012, 02:03 PM
MY_MODEL - by El Forum - 11-26-2012, 02:13 PM
MY_MODEL - by El Forum - 11-26-2012, 04:52 PM



Theme © iAndrew 2016 - Forum software by © MyBB