You are here

function _customerror_enum_errors in Customerror 6

Same name and namespace in other branches
  1. 5 customerror.module \_customerror_enum_errors()
  2. 7 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
Callback, page arguments.
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 => t('requested page not found'),
    403 => t('access denied'),
  );

  // Sorting array here by keys so they are logically sorted on form.
  ksort($errors);
  return $errors;
}