This module allows the site admin to create custom error pages for HTTP status codes 403 (access denied) and 404 (page not found), without the need to create nodes for each of them.

Main features:

  • Configurable page title and descriptions.
  • There are no author and date/time headers as with normal nodes.
  • Any HTML formatted text can be be put in the page body.
  • The error pages are themable.
  • Users who are not logged in and try to access an area that requires login will be redirected to the page they were trying to access after they login.
  • Allows custom redirects for 404s.

Since the error pages are not real nodes, they do not have a specific content type, and will not show up in node listings, or in a Popular Content block. They also can be seen by anonymous visitors on sites that require log-in to see content.

At present, the module can be set up to handle 403 and 404 errors. Drupal only allows those two status codes to be assigned custom pages. However, the design of the module is flexible and can accommodate future status codes easily.

Installation

Please see the README document included with the module for installation instructions.

Custom error alternate for authenticated [Drupal 7 branch only]

The Drupal 7 version of the project comes with a submodule: Custom error alternate for authenticated (Short name: customerroralt) .

Enabling this submodule lets the administrator create an "insufficient permissions" page for authenticated users, distinct from a "please log in" page for anonymous users.

Support Status

This project is considered complete. However, reported bugs for the Drupal 7 and 10 branches will be fixed if they come wit patches or merge requests reaching RTBC. Versions beyond EOL are no longer supported. Community support in the form of patches are very welcome. For QA, the project needs community support in the form of review of patches, development versions and releases.

The primary goal of the Customerror module is to remain lean and simple. This means that not all feature requests will be implemented, even if they are a good idea. Feature requests accompanied by patches are more likely to make it into a release.

The maintainer hopes that the community is willing to help out by answering & closing support requests.

Known problems

  • Customerror lets you assign an explicit theme to use for error pages. However, if you also use a custom Administration theme, the custom administration theme will be used for error pages that are on the admin path. See #278575: Admin theme is used on error pages below /admin for details.
  • Customerror allows custom redirects for 404s. However, if you also use the Redirect module, you should refrain from using the redirect feature of Customerror.

Credits

Principal author is Khalid Baheyeldin of 2bits.com.

Port to Drupal 7 port has been overseen by Gisle Hannemyr.

The authors can be contacted for paid customizations of this module as well as Drupal consulting, installation, development, and customizations.

Supporting organizations: 
maintains the project
development and maintenance of Drupal 8, Drupal 9 (modern Drupal) version.

Project information

Releases