<?php

class custom404 extends CI_Controller {

    public function __construct() {
        parent::__construct();
        $this->ci = & get_instance();
        $this->ci->load->config('url', TRUE);
    }

    public function index() {
        $this->output->set_status_header('404');
        $lk =  $this->ci->config->item('url_base', 'url');
        redirect($lk);
    }

}
