summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--includes/common.inc4
-rw-r--r--includes/menu.inc7
-rw-r--r--modules/system.module10
-rw-r--r--modules/system/system.module10
4 files changed, 17 insertions, 14 deletions
diff --git a/includes/common.inc b/includes/common.inc
index 198163900..ae42390a4 100644
--- a/includes/common.inc
+++ b/includes/common.inc
@@ -254,11 +254,11 @@ function drupal_goto($path = '', $query = NULL, $fragment = NULL) {
/**
- * Generates a site offline message
+ * Generates a site off-line message
*/
function drupal_site_offline() {
drupal_set_header('HTTP/1.0 503 Service unavailable');
- drupal_set_title(t('Site offline'));
+ drupal_set_title(t('Site off-line'));
print theme('maintenance_page', variable_get('site_offline_message',
t('%site is currently under maintenance. We should be back shortly. Thank you for your patience.', array('%site' => variable_get('site_name', t('This Drupal site'))))));
}
diff --git a/includes/menu.inc b/includes/menu.inc
index cc48396ff..33fcd919c 100644
--- a/includes/menu.inc
+++ b/includes/menu.inc
@@ -1312,10 +1312,10 @@ function _menu_build_local_tasks($pid) {
}
/**
- * Returns TRUE if the is offline for maintenance.
+ * Returns TRUE if the is off-line for maintenance.
*/
function _menu_site_is_offline() {
- // Check if site is set to offline mode
+ // Check if site is set to off-line mode
if (variable_get('site_offline', 0)) {
// Check if the user has administration privileges
if (!user_access('administer site configuration')) {
@@ -1324,6 +1324,9 @@ function _menu_site_is_offline() {
return TRUE;
}
}
+ else {
+ drupal_set_message(t('Operating in off-line mode.'));
+ }
}
return FALSE;
}
diff --git a/modules/system.module b/modules/system.module
index bf2250d79..f96de2e92 100644
--- a/modules/system.module
+++ b/modules/system.module
@@ -442,7 +442,7 @@ function system_view_general() {
);
- // Site offline/maintenance settings
+ // Site off-line/maintenance settings
$form['site_status'] = array(
'#type' => 'fieldset',
'#title' => t('Site maintenance'),
@@ -453,15 +453,15 @@ function system_view_general() {
'#type' => 'radios',
'#title' => t('Site status'),
'#default_value' => variable_get('site_offline', 0),
- '#options' => array(t('Online'), t('Offline')),
- '#description' => t('When set to "Online", all visitors will be able to browse your site normally. When set to "Offline", only users with the "administer site configuration" permission will be able to access your site to perform maintenance, all other visitors will see the site offline message configured below.')
+ '#options' => array(t('Online'), t('Off-line')),
+ '#description' => t('When set to "Online", all visitors will be able to browse your site normally. When set to "Off-line", only users with the "administer site configuration" permission will be able to access your site to perform maintenance; all other visitors will see the site off-line message configured below. Authorized users can log in during "Off-line" mode directly via the <a href="%user-login">user login</a> page.', array('%user-login' => url('user'))),
);
$form['site_status']['site_offline_message'] = array(
'#type' => 'textarea',
- '#title' => t('Site offline message'),
+ '#title' => t('Site off-line message'),
'#default_value' => variable_get('site_offline_message', t('%site is currently under maintenance. We should be back shortly. Thank you for your patience.', array('%site' => variable_get('site_name', t('This Drupal site'))))),
- '#description' => t('Message to show visitors when site is offline.')
+ '#description' => t('Message to show visitors when the site is in off-line mode.')
);
// String handling: report status and errors.
diff --git a/modules/system/system.module b/modules/system/system.module
index bf2250d79..f96de2e92 100644
--- a/modules/system/system.module
+++ b/modules/system/system.module
@@ -442,7 +442,7 @@ function system_view_general() {
);
- // Site offline/maintenance settings
+ // Site off-line/maintenance settings
$form['site_status'] = array(
'#type' => 'fieldset',
'#title' => t('Site maintenance'),
@@ -453,15 +453,15 @@ function system_view_general() {
'#type' => 'radios',
'#title' => t('Site status'),
'#default_value' => variable_get('site_offline', 0),
- '#options' => array(t('Online'), t('Offline')),
- '#description' => t('When set to "Online", all visitors will be able to browse your site normally. When set to "Offline", only users with the "administer site configuration" permission will be able to access your site to perform maintenance, all other visitors will see the site offline message configured below.')
+ '#options' => array(t('Online'), t('Off-line')),
+ '#description' => t('When set to "Online", all visitors will be able to browse your site normally. When set to "Off-line", only users with the "administer site configuration" permission will be able to access your site to perform maintenance; all other visitors will see the site off-line message configured below. Authorized users can log in during "Off-line" mode directly via the <a href="%user-login">user login</a> page.', array('%user-login' => url('user'))),
);
$form['site_status']['site_offline_message'] = array(
'#type' => 'textarea',
- '#title' => t('Site offline message'),
+ '#title' => t('Site off-line message'),
'#default_value' => variable_get('site_offline_message', t('%site is currently under maintenance. We should be back shortly. Thank you for your patience.', array('%site' => variable_get('site_name', t('This Drupal site'))))),
- '#description' => t('Message to show visitors when site is offline.')
+ '#description' => t('Message to show visitors when the site is in off-line mode.')
);
// String handling: report status and errors.