summaryrefslogtreecommitdiff
path: root/modules/watchdog.module
diff options
context:
space:
mode:
authorDries Buytaert <dries@buytaert.net>2004-07-03 14:10:09 +0000
committerDries Buytaert <dries@buytaert.net>2004-07-03 14:10:09 +0000
commit3fb070f419bd873c40d2df5d00cca3565aeef984 (patch)
tree0c3220171134ad44c428d69d68bcf6ade7fd5283 /modules/watchdog.module
parentcca82f8ee45876f8b231e2388680a1efdbe5a280 (diff)
downloadbrdo-3fb070f419bd873c40d2df5d00cca3565aeef984.tar.gz
brdo-3fb070f419bd873c40d2df5d00cca3565aeef984.tar.bz2
- Patch #8952 by Morbus: watchdog module beautifications.
* slightly reorders the functions in anticipation of http://drupal.org/node/view/9010. * reorders help definitions to match the alphabetical nature of the menu items. * tweaked visual appearance of menu code (whitespace, etc.) * minor tweaks to "warning" help to match style of others.
Diffstat (limited to 'modules/watchdog.module')
-rw-r--r--modules/watchdog.module44
1 files changed, 22 insertions, 22 deletions
diff --git a/modules/watchdog.module b/modules/watchdog.module
index 9f88e92c4..f8c0dcc2f 100644
--- a/modules/watchdog.module
+++ b/modules/watchdog.module
@@ -22,54 +22,54 @@ function watchdog_help($section = 'admin/help#watchdog') {
return t('<p>The watchdog module monitors your web site, capturing system events in a log to be reviewed by an authorized individual at a later time. The watchdog log is simply a list of recorded events containing usage data, performance data, errors, warnings and operational information. It is vital to <a href="%watchdog">check the watchdog report</a> on a regular basis as it is often the only way to tell what is going on.</p>', array('%watchdog' => url('admin/logs')));
case 'admin/logs':
return t('The watchdog module monitors your web site, capturing system events in a log to be reviewed by an authorized individual at a later time. The watchdog log is simply a list of recorded events containing usage data, performance data, errors, warnings and operational information. It is vital to check the watchdog report on a regular basis as it is often the only way to tell what is going on.');
- case 'admin/logs/user':
- return t('Watchdog events that have to do with users and their accounts.');
- case 'admin/logs/regular':
- return t('Watchdog events that are "normal" and have no other classification.');
+ case 'admin/logs/error':
+ return t('Watchdog events about PHP and database errors.');
case 'admin/logs/httpd':
return t('Watchdog events that are from the web server, like 404s, etc.');
- case 'admin/logs/special':
- return t('Watchdog events about adding, changing, and moderating nodes and comments.');
+ case 'admin/logs/regular':
+ return t('Watchdog events that are "normal" and have no other classification.');
case 'admin/logs/search':
return t('Watchdog events showing what users have searched for.');
- case 'admin/logs/error':
- return t('Watchdog events about PHP and database errors.');
+ case 'admin/logs/special':
+ return t('Watchdog events about adding, changing, and moderating nodes and comments.');
+ case 'admin/logs/user':
+ return t('Watchdog events that have to do with users and their accounts.');
case 'admin/logs/warning':
- return t('Watchdog warning events. These events don\'t stop Drupal from running, but are things you should know.');
+ return t('Watchdog events that don\'t stop normal operation, but are things you should know.');
case 'admin/modules#description':
return t('Logs and records system events.');
}
}
/**
- * Implementation of hook_perm().
- */
-function watchdog_perm() {
- return array('administer watchdog');
-}
-
-/**
* Implementation of hook_menu().
*/
function watchdog_menu() {
$items = array();
+
$items[] = array('path' => 'admin/logs', 'title' => t('logs'),
- 'callback' => 'watchdog_overview',
- 'access' => user_access('administer watchdog'));
+ 'callback' => 'watchdog_overview', 'access' => user_access('administer watchdog'));
+
$items[] = array('path' => 'admin/logs/view', 'title' => t('view details'),
- 'callback' => 'watchdog_view',
- 'access' => user_access('administer watchdog'),
+ 'callback' => 'watchdog_view', 'access' => user_access('administer watchdog'),
'type' => MENU_CALLBACK);
+
if (arg(1) == 'logs') {
foreach (_watchdog_get_message_types() as $type) {
- $items[] = array('path' => 'admin/logs/'. $type, 'title' => t($type),
- 'type' => MENU_DYNAMIC_ITEM);
+ $items[] = array('path' => 'admin/logs/'. $type, 'title' => t($type), 'type' => MENU_DYNAMIC_ITEM);
}
}
return $items;
}
/**
+ * Implementation of hook_perm().
+ */
+function watchdog_perm() {
+ return array('administer watchdog');
+}
+
+/**
* Implementation of hook_cron().
*
* Remove expired log messages.