[eluser]Nexus Rex[/eluser]
I also have a similar issue:
File: system/application/libraries/My_controller.php
Code:
<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');
// application/libraries/My_controller.php
class My_controller extends Controller {
var $partial = 'debug/echo';
function My_controller() {
parent::Controller();
$this->_get_partial();
$this->_get_model();
}
function _get_partial() {
$uri = $this->router->class . '/' . $this->router->method;
if (is_file(realpath(dirname(__FILE__) . '/../views/' . $uri . EXT))) {
$this->partial = $this->router->class . '/' . $this->router->method;
}
}
function _get_model() {
$uri = substr($this->router->class, 0, -1);
if (is_file(realpath(dirname(__FILE__) . '/../models/' . $uri . EXT))) {
$this->load->model($uri);
}
}
}
When I try to create a members controller that extends My_controller I get an error.
FATAL ERROR: Class 'My_controller' not found in /home/latinole/public_html/directory/system/application/controllers/members.php on line 3
I have tried autoloading the library, moving it to /system/application/controllers/, all to no avail.