? sites/default/files
? sites/default/settings.php
Index: modules/system/system.admin.inc
===================================================================
RCS file: /cvs/drupal/drupal/modules/system/system.admin.inc,v
retrieving revision 1.284
diff -u -p -r1.284 system.admin.inc
--- modules/system/system.admin.inc	21 May 2010 11:37:55 -0000	1.284
+++ modules/system/system.admin.inc	24 May 2010 21:57:31 -0000
@@ -1500,40 +1500,83 @@ function system_ip_blocking_delete_submi
  * @see system_settings_form()
  */
 function system_site_information_settings() {
-  $form['site_name'] = array(
+  $form['site_information'] = array(
+    '#type' => 'fieldset',
+    '#title' => t('Site Details'),
+  );
+  $form['site_information']['site_name'] = array(
     '#type' => 'textfield',
     '#title' => t('Site name'),
     '#default_value' => variable_get('site_name', 'Drupal'),
     '#required' => TRUE
   );
-  $form['site_slogan'] = array(
+  $form['site_information']['site_slogan'] = array(
     '#type' => 'textfield',
     '#title' => t('Slogan'),
     '#default_value' => variable_get('site_slogan', ''),
     '#description' => t("How this is used depends on your site's theme."),
   );
-  $form['site_mail'] = array(
+  $form['site_information']['site_mail'] = array(
     '#type' => 'textfield',
     '#title' => t('E-mail address'),
     '#default_value' => variable_get('site_mail', ini_get('sendmail_from')),
     '#description' => t("The <em>From</em> address in automated e-mails sent during registration and new password requests, and other notifications. (Use an address ending in your site's domain to help prevent this e-mail being flagged as spam.)"),
     '#required' => TRUE,
   );
-  $form['site_frontpage'] = array(
-    '#type' => 'textfield',
-    '#title' => t('Default front page'),
-    '#default_value' => drupal_get_path_alias(variable_get('site_frontpage', 'node')),
-    '#size' => 40,
-    '#description' => t('The home page displays content from this relative URL. If unsure, specify "node".'),
-    '#field_prefix' => url(NULL, array('absolute' => TRUE)) . (variable_get('clean_url', 0) ? '' : '?q='),
-    '#required' => TRUE,
+  $form['front_page'] = array(
+    '#type' => 'fieldset',
+    '#title' => t('Front Page'),
   );
-  $form['default_nodes_main'] = array(
+  $form['front_page']['default_nodes_main'] = array(
     '#type' => 'select', '#title' => t('Number of posts on front page'),
     '#default_value' => variable_get('default_nodes_main', 10),
     '#options' => drupal_map_assoc(array(1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 15, 20, 25, 30)),
     '#description' => t('The maximum number of posts displayed on overview pages such as the front page.')
   );
+  $form['front_page']['site_frontpage'] = array(
+    '#type' => 'textfield',
+    '#title' => t('Default front page'),
+    '#default_value' => (variable_get('site_frontpage')!='node'?drupal_get_path_alias(variable_get('site_frontpage', 'node')):''),
+    '#size' => 40,
+    '#description' => t('Optionally, specify a relative URL to display as the front page.  Leave blank to display the default content feed.'),
+    '#field_prefix' => url(NULL, array('absolute' => TRUE)) . (variable_get('clean_url', 0) ? '' : '?q='),
+  );
+
+  $form['#validate'][] = 'system_site_information_settings_validate';
+
+  return system_settings_form($form, FALSE);
+}
+
+/**
+ * Validate the submitted site-information form.
+ */
+function system_site_information_settings_validate($form, &$form_state) {
+  // Validate the e-mail address.
+  if ($error = user_validate_mail($form_state['values']['site_mail'])) {
+    form_set_error('site_mail', $error);
+  }
+  // Check for empty front page path.
+  if (empty($form_state['values']['site_frontpage'])) {
+    // Set to default "node"
+    form_set_value($form['front_page']['site_frontpage'], 'node', $form_state);
+  }
+  else {
+    // Get the normal path of the front page.
+    form_set_value($form['front_page']['site_frontpage'], drupal_get_normal_path($form_state['values']['site_frontpage']), $form_state);
+  }
+  // Validate front page path.
+  if (!drupal_valid_path($form_state['values']['site_frontpage'])) {
+    form_set_error('site_frontpage', t("The path '@path' is either invalid or you do not have access to it.", array('@path' => $form_state['values']['site_frontpage'])));
+  }
+}
+
+/**
+ * Form builder; Error pages form.
+ *
+ * @ingroup forms
+ * @see system_settings_form()
+ */
+function system_error_pages_settings() {
   $form['site_403'] = array(
     '#type' => 'textfield',
     '#title' => t('Default 403 (access denied) page'),
@@ -1550,33 +1593,84 @@ function system_site_information_setting
     '#description' => t('This page is displayed when no other content matches the requested document. Leave blank to display a generic "page not found" page.'),
     '#field_prefix' => url(NULL, array('absolute' => TRUE)) . (variable_get('clean_url', 0) ? '' : '?q=')
   );
-  $form['cron_safe_threshold'] = array(
+  
+  $form['#validate'][] = 'system_error_pages_settings_validate';
+  
+  return system_settings_form($form, FALSE);
+}
+
+/**
+ * Validate the submitted error pages form.
+ */
+function system_error_pages_settings_validate($form, &$form_state) {
+  // Get the normal paths of both error pages.
+  if (!empty($form_state['values']['site_403'])) {
+    form_set_value($form['site_403'], drupal_get_normal_path($form_state['values']['site_403']), $form_state);
+  }
+  if (!empty($form_state['values']['site_404'])) {
+    form_set_value($form['site_404'], drupal_get_normal_path($form_state['values']['site_404']), $form_state);
+  }
+  // Validate 403 error path.
+  if (!empty($form_state['values']['site_403']) && !drupal_valid_path($form_state['values']['site_403'])) {
+    form_set_error('site_403', t("The path '@path' is either invalid or you do not have access to it.", array('@path' => $form_state['values']['site_403'])));
+  }
+  // Validate 404 error path.
+  if (!empty($form_state['values']['site_404']) && !drupal_valid_path($form_state['values']['site_404'])) {
+    form_set_error('site_404', t("The path '@path' is either invalid or you do not have access to it.", array('@path' => $form_state['values']['site_404'])));
+  }
+}
+
+/**
+ * Form builder; Cron form.
+ *
+ * @ingroup forms
+ * @see system_settings_form()
+ */
+function system_cron_settings() {
+  $form['run_cron'] = array(
+    '#type' => 'fieldset',
+    '#title' => t('Run Cron'),
+  );
+  $status = '<p><em>' . t('Cron was last run %cron-last ago.  For more information, visit the <a href="@status-report-url">status report page</a>.', array('%cron-last' => format_interval(REQUEST_TIME - variable_get('cron_last')), '@status-report-url' => url('admin/reports/status'))) . '</em></p>';
+  $form['run_cron']['status'] = array(
+    '#markup' => $status,
+  );
+  $form['run_cron']['run'] = array(
+    '#type' => 'submit',
+    '#value' => t('Run cron'),
+    '#submit' => array('system_run_cron_submit'),
+  );
+  
+  $form['automatic_cron'] = array(
+    '#type' => 'fieldset',
+    '#title' => t('Automatic Settings'),
+  );
+  $form['automatic_cron']['cron_safe_threshold'] = array(
     '#type' => 'select',
     '#title' => t('Automatically run cron'),
     '#default_value' => variable_get('cron_safe_threshold', DRUPAL_CRON_DEFAULT_THRESHOLD),
     '#options' => array(0 => t('Never')) + drupal_map_assoc(array(3600, 10800, 21600, 43200, 86400, 604800), 'format_interval'),
-    '#description' => t('When enabled, the site will check whether cron has been run in the configured interval and automatically run it upon the next page request. For more information visit the <a href="@status-report-url">status report page</a>.', array('@status-report-url' => url('admin/reports/status'))),
+    '#description' => t('When enabled, the site will check whether cron has been run in the configured interval and automatically run it upon the next page request.'),
   );
-
-  $form['#validate'][] = 'system_site_information_settings_validate';
-
+  
   return system_settings_form($form, FALSE);
 }
 
 /**
- * Validate the submitted site-information form.
+ * Submit callback; run cron.
+ *
+ * @ingroup forms
  */
-function system_site_information_settings_validate($form, &$form_state) {
-  // Validate the e-mail address.
-  if ($error = user_validate_mail($form_state['values']['site_mail'])) {
-    form_set_error('site_mail', $error);
+function system_run_cron_submit($form, &$form_state) {
+  // Run cron manually from Cron form.
+  if (drupal_cron_run()) {
+    drupal_set_message(t('Cron ran successfully.'));
   }
-  // Get the normal path of the front page.
-  form_set_value($form['site_frontpage'], drupal_get_normal_path($form_state['values']['site_frontpage']), $form_state);
-  // Validate front page path.
-  if (!drupal_valid_path($form_state['values']['site_frontpage'])) {
-    form_set_error('site_frontpage', t("The path '@path' is either invalid or you do not have access to it.", array('@path' => $form_state['values']['site_frontpage'])));
+  else {
+    drupal_set_message(t('Cron run failed.'), 'error');
   }
+
+  drupal_goto('admin/config/system/cron');
 }
 
 /**
Index: modules/system/system.module
===================================================================
RCS file: /cvs/drupal/drupal/modules/system/system.module,v
retrieving revision 1.933
diff -u -p -r1.933 system.module
--- modules/system/system.module	20 May 2010 08:47:00 -0000	1.933
+++ modules/system/system.module	24 May 2010 21:57:33 -0000
@@ -138,6 +138,8 @@ function system_help($path, $arg) {
       return '<p>' . t('IP addresses listed here are blocked from your site before any modules are loaded. You may add IP addresses to the list, or delete existing entries.') . '</p>';
     case 'admin/reports/status':
       return '<p>' . t("Here you can find a short overview of your site's parameters as well as any problems detected with your installation. It may be useful to copy and paste this information into support requests filed on drupal.org's support forums and project issue queues.") . '</p>';
+    case 'admin/config/user-interface/error-pages':
+      return '<p>' . t("Specify paths to be displayed as errors to site visitors when the content cannot be found (404) or when access has been denied to the user (403).  Leave each field blank to use generic error pages.") . '</p>';
   }
 }
 
@@ -957,13 +959,31 @@ function system_menu() {
   );
   $items['admin/config/system/site-information'] = array(
     'title' => 'Site information',
-    'description' => 'Change site name, e-mail address, slogan, default front page, number of posts per page, error pages and cron.',
+    'description' => 'Change site name, e-mail address, slogan, default front page, and number of posts per page.',
     'page callback' => 'drupal_get_form',
     'page arguments' => array('system_site_information_settings'),
     'access arguments' => array('administer site configuration'),
     'file' => 'system.admin.inc',
     'weight' => -20,
   );
+  $items['admin/config/system/cron'] = array(
+    'title' => 'Cron',
+    'description' => 'Configure scheduled jobs.',
+    'page callback' => 'drupal_get_form',
+    'page arguments' => array('system_cron_settings'),
+    'access arguments' => array('administer site configuration'),
+    'file' => 'system.admin.inc',
+    'weight' => 20,
+  );
+  $items['admin/config/system/error-pages'] = array(
+    'title' => 'Error Pages',
+    'description' => 'Configure custom error pages.',
+    'page callback' => 'drupal_get_form',
+    'page arguments' => array('system_error_pages_settings'),
+    'access arguments' => array('access administration pages'),
+    'file' => 'system.admin.inc',
+    'weight' => 25,
+  );
 
   // Additional categories
   $items['admin/config/user-interface'] = array(
Index: modules/system/system.test
===================================================================
RCS file: /cvs/drupal/drupal/modules/system/system.test,v
retrieving revision 1.124
diff -u -p -r1.124 system.test
--- modules/system/system.test	20 Apr 2010 09:48:06 -0000	1.124
+++ modules/system/system.test	24 May 2010 21:57:34 -0000
@@ -458,7 +458,7 @@ class CronRunTestCase extends DrupalWebT
     // Disable the cron threshold through the interface.
     $admin_user = $this->drupalCreateUser(array('administer site configuration'));
     $this->drupalLogin($admin_user);
-    $this->drupalPost('admin/config/system/site-information', array('cron_safe_threshold' => 0), t('Save configuration'));
+    $this->drupalPost('admin/config/system/cron', array('cron_safe_threshold' => 0), t('Save configuration'));
     $this->assertText(t('The configuration options have been saved.'));
     $this->drupalLogout();
 
@@ -574,7 +574,7 @@ class AccessDeniedTestCase extends Drupa
     $node = $this->drupalCreateNode($edit);
 
     // Use a custom 403 page.
-    $this->drupalPost('admin/config/system/site-information', array('site_403' => 'node/' . $node->nid), t('Save configuration'));
+    $this->drupalPost('admin/config/system/error-pages', array('site_403' => 'node/' . $node->nid), t('Save configuration'));
 
     $this->drupalGet('admin');
     $this->assertText($node->title, t('Found the custom 403 page'));
@@ -588,7 +588,7 @@ class AccessDeniedTestCase extends Drupa
 
     // Log back in and remove the custom 403 page.
     $this->drupalLogin($this->admin_user);
-    $this->drupalPost('admin/config/system/site-information', array('site_403' => ''), t('Save configuration'));
+    $this->drupalPost('admin/config/system/error-pages', array('site_403' => ''), t('Save configuration'));
 
     // Logout and check that the user login block is shown on default 403 pages.
     $this->drupalLogout();
@@ -609,10 +609,10 @@ class AccessDeniedTestCase extends Drupa
       'name' => $this->admin_user->name,
       'pass' => $this->admin_user->pass_raw,
     );
-    $this->drupalPost('admin/config/system/site-information', $edit, t('Log in'));
+    $this->drupalPost('admin/config/system/error-pages', $edit, t('Log in'));
 
     // Check that we're still on the same page.
-    $this->assertText(t('Site information'));
+    $this->assertText(t('Error Pages'));
   }
 }
 
@@ -652,7 +652,7 @@ class PageNotFoundTestCase extends Drupa
     $node = $this->drupalCreateNode($edit);
 
     // Use a custom 404 page.
-    $this->drupalPost('admin/config/system/site-information', array('site_404' => 'node/' . $node->nid), t('Save configuration'));
+    $this->drupalPost('admin/config/system/error-pages', array('site_404' => 'node/' . $node->nid), t('Save configuration'));
 
     $this->drupalGet($this->randomName(10));
     $this->assertText($node->title, t('Found the custom 404 page'));
