function show_404($page = '', $log_error = TRUE) { if (trim($page) == '') { $page = $_SERVER['REQUEST_URI']; } return parent::show_404($page, $log_error); }
function show_404($lang_id = 'br') { if (is_callable('redirect') && is_callable('site_url_lang')) { redirect(site_url_lang('/404', $lang_id)); } else { parent::show_404(); } }
function show_404($page = '', $log_error = TRUE) { $this->config =& get_config(); $base_url = $this->config['base_url']; header("location: " . $base_url . 'error/h404/' . $page); //include() //include($this->absolute_path() . "index.php?error/404/" . $page); die; // Header didn't redirect, go to a backup parent::show_404($page, $log_error); }
/** * 404 Page Not Found Handler * * @access private * @param string the page * @param bool log error yes/no * @return string */ function show_404($page = '', $log_error = TRUE) { if ($this->input->is_ajax_request()) { $heading = "404 Page Not Found"; $message = "The page you requested was not found."; // By default we log this, but allow a dev to skip it if ($log_error) { log_message('error', '404 Page Not Found --> ' . $page); } $this->output->error(404, "page: {$page} is not found."); } else { parent::show_404($page, $log_error); } }
/** * 404 Page Handler * * This function is similar to the show_error() function above * However, instead of the standard error template it displays * 404 errors. * * @access public * @return void */ function show_404($page = '') { if (!class_exists('CI_Exceptions')) { include_once BASEPATH . 'libraries/Exceptions.php'; } $error = new CI_Exceptions(); $error->show_404($page); exit; }