New module 'Custom error'

This commit is contained in:
Manuel Cillero 2017-07-26 22:28:06 +02:00
parent 314a279f79
commit d1f15e39fd
7 changed files with 1030 additions and 0 deletions

View file

@ -0,0 +1,19 @@
<?php
/**
* @file
* Install and uninstall hooks.
*/
/**
* Implements hook_uninstall().
*/
function customerror_uninstall() {
db_query("DELETE FROM {variable} WHERE name LIKE 'customerror_%'");
foreach (_customerror_enum_errors() as $code => $desc) {
if (variable_get('site_' . $code, '') == 'customerror/' . $code) {
variable_del('site_' . $code, '');
}
}
}