[eluser]davidbehler[/eluser]
Works fine for me. Using a fresh CI 1.7.2 install I did this:
Create a new file application/libraries/MY_Controller.php with this content:
Code:
<?php
class MY_Controller extends Controller {
function MY_Controller()
{
parent::Controller();
}
function _output($output)
{
echo str_replace('background-color: #fff;', 'background-color: blue;', $output);
}
}
Edit application/controllers/welcome.php and made it extend MY_Controller instead of Controller:
Code:
<?php
class Welcome extends MY_Controller {
function Welcome()
{
parent::Controller();
}
function index()
{
$this->load->view('welcome_message');
}
}
Going to index.php/welcome I see the normal welcome dummy page with a blue background instead of the white one.
Make sure you have set the subclass prefix correctly in application/config/config.php:
Code:
$config['subclass_prefix'] = 'MY_';
Maybe you can get it to work now