function _customerror_enum_errors in Customerror 7
Same name and namespace in other branches
- 5 customerror.module \_customerror_enum_errors()
- 6 customerror.module \_customerror_enum_errors()
Helper function to set up array of error coedes.
This is where the error codes and their default descriptions are stored. Add here as necessary.
3 calls to _customerror_enum_errors()
- customerror_admin_settings in ./
customerror.module - Displays the module settings form.
- customerror_uninstall in ./
customerror.install - Implements hook_uninstall().
- _customerror_fetch_error in ./
customerror.module - Fetch error.
File
- ./
customerror.module, line 18 - Enables custom 404 (not found) and 403 (access denied) pages in Drupal.
Code
function _customerror_enum_errors() {
$errors = array(
404 => array(
t('Page not found'),
t('The requested page could not be found.'),
),
403 => array(
t('Access denied'),
t('You are not authorized to access this page.'),
),
);
// Sorting array here by keys so they are logically sorted on form.
ksort($errors);
return $errors;
}