From 8905544936b046fd49e1697acd9ff633c7d5cf15 Mon Sep 17 00:00:00 2001 From: Dries Buytaert Date: Wed, 18 Aug 2010 01:54:36 +0000 Subject: - Patch #881540 by bjaspan: openlog() identity argument and unrelated bug fixes. --- modules/syslog/syslog.module | 28 ++++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-) (limited to 'modules/syslog/syslog.module') diff --git a/modules/syslog/syslog.module b/modules/syslog/syslog.module index 590dd9dae..20f8a2823 100644 --- a/modules/syslog/syslog.module +++ b/modules/syslog/syslog.module @@ -37,14 +37,14 @@ function syslog_help($path, $arg) { * Implements hook_form_FORM_ID_alter(). */ function syslog_form_system_logging_settings_alter(&$form, &$form_state) { + $help = module_exists('help') ? ' ' . l(t('More information'), 'admin/help/syslog') . '.' : NULL; + $form['syslog_identity'] = array( + '#type' => 'textfield', + '#title' => t('Syslog identity'), + '#default_value' => variable_get('syslog_identity', 'drupal'), + '#description' => t('A string that will be prepended to every message logged to Syslog. If you have multiple sites logging to the same Syslog log file, a unique identity per site makes it easy to tell the log entries apart.') . $help, + ); if (defined('LOG_LOCAL0')) { - $help = module_exists('help') ? ' ' . l(t('More information'), 'admin/help/syslog') . '.' : NULL; - $form['syslog_identity'] = array( - '#type' => 'textfield', - '#title' => t('Syslog identity'), - '#default_value' => variable_get('syslog_identity', 'drupal'), - '#description' => t('A string that will be prepended to every message logged to Syslog. If you have multiple sites logging to the same Syslog log file, a unique identity per site makes it easy to tell the log entries apart.') . $help, - ); $form['syslog_facility'] = array( '#type' => 'select', '#title' => t('Syslog facility'), @@ -52,14 +52,14 @@ function syslog_form_system_logging_settings_alter(&$form, &$form_state) { '#options' => syslog_facility_list(), '#description' => t('Depending on the system configuration, Syslog and other logging tools use this code to identify or filter messages from within the entire system log.') . $help, ); - $form['syslog_format'] = array( - '#type' => 'textarea', - '#title' => t('Syslog format'), - '#default_value' => variable_get('syslog_format', '!base_url|!timestamp|!type|!ip|!request_uri|!referer|!uid|!link|!message'), - '#description' => t('Specify the format of the syslog entry. Available variables are:
!base_url
Base URL of the site.
!timestamp
Unix timestamp of the log entry.
!type
The category to which this message belongs.
!ip
IP address of the user triggering the message.
!request_uri
The requested URI.
!referer
HTTP Referer if available.
!uid
User ID.
!link
A link to associate with the message.
!message
The message to store in the log.
'), - ); - $form['actions']['#weight'] = 1; } + $form['syslog_format'] = array( + '#type' => 'textarea', + '#title' => t('Syslog format'), + '#default_value' => variable_get('syslog_format', '!base_url|!timestamp|!type|!ip|!request_uri|!referer|!uid|!link|!message'), + '#description' => t('Specify the format of the syslog entry. Available variables are:
!base_url
Base URL of the site.
!timestamp
Unix timestamp of the log entry.
!type
The category to which this message belongs.
!ip
IP address of the user triggering the message.
!request_uri
The requested URI.
!referer
HTTP Referer if available.
!uid
User ID.
!link
A link to associate with the message.
!message
The message to store in the log.
'), + ); + $form['actions']['#weight'] = 1; } /** -- cgit v1.2.3