system_settings_form

  1. drupal
    1. drupal6
    2. drupal7
Versionen
drupal6 system_settings_form($form)
drupal7 system_settings_form($form, $automatic_defaults = TRUE)

Add default buttons to a form and set its prefix.

Übergabeparameter

$form An associative array containing the structure of the form.

$automatic_defaults Automatically load the saved values for each field from the system variables (defaults to TRUE).

Rückgabewert

The form structure.

See also

system_settings_form_submit()

Verwandte Themen

▾ 23 functions call system_settings_form()

blogapi_admin_settings in modules/blogapi/blogapi.module
Add some settings to the admin_settings form.
book_admin_settings in modules/book/book.admin.inc
Builds and returns the book settings form.
contact_admin_settings in modules/contact/contact.admin.inc
filter_admin_configure in modules/filter/filter.admin.inc
Build a form to change the settings for a format's filters.
forum_admin_settings in modules/forum/forum.admin.inc
Form builder for the forum settings page.
menu_configure in modules/menu/menu.admin.inc
Menu callback; Build the form presenting menu configuration options.
node_configure in modules/node/node.admin.inc
Menu callback; presents general node configuration options.
search_admin_settings in modules/search/search.admin.inc
Menu callback; displays the search module settings page.
statistics_settings_form in modules/statistics/statistics.admin.inc
Form builder; Configure access logging.
SystemSettingsForm::testAutomaticDefaults in modules/system/system.test
Tests the handling of automatic defaults in systems_settings_form().
system_clean_url_settings in modules/system/system.admin.inc
Form builder; Configure Clean URL settings.
system_file_system_settings in modules/system/system.admin.inc
Form builder; Configure the site file handling.
system_image_toolkit_settings in modules/system/system.admin.inc
Form builder; Configure site image toolkit usage.
system_logging_settings in modules/system/system.admin.inc
Form builder; Configure error reporting settings.
system_performance_settings in modules/system/system.admin.inc
Form builder; Configure site performance settings.
system_regional_settings in modules/system/system.admin.inc
Form builder; Configure the site date and time settings.
system_rss_feeds_settings in modules/system/system.admin.inc
Form builder; Configure how the site handles RSS feeds.
system_site_information_settings in modules/system/system.admin.inc
Form builder; The general site information form.
system_site_maintenance_mode in modules/system/system.admin.inc
Form builder; Configure the site's maintenance status.
system_theme_settings in modules/system/system.admin.inc
Form builder; display theme configuration for entire site and individual themes.
update_settings in modules/update/update.settings.inc
Form builder for the update settings tab.
upload_admin_settings in modules/upload/upload.admin.inc
Menu callback for the upload settings form.
user_admin_settings in modules/user/user.admin.inc
Form builder; Configure user settings for this site.

Code

modules/system/system.module, line 1411

<?php
function system_settings_form($form, $automatic_defaults = TRUE) {
  $form['buttons']['submit'] = array('#type' => 'submit', '#value' => t('Save configuration') );
  $form['buttons']['reset'] = array('#type' => 'submit', '#value' => t('Reset to defaults') );

  if ($automatic_defaults) {
    $form = _system_settings_form_automatic_defaults($form);
  }

  if (!empty($_POST) && form_get_errors()) {
    drupal_set_message(t('The settings have not been saved because of the errors.'), 'error');
  }
  $form['#submit'][] = 'system_settings_form_submit';
  $form['#theme'] = 'system_settings_form';
  return $form;
}
?>

Kommentare

Kommentar hinzufügen

Der Inhalt dieses Feldes wird nicht öffentlich zugänglich angezeigt.
  • Internet- und E-Mail-Adressen werden automatisch umgewandelt.
  • Zulässige HTML-Tags: <a> <em> <strong> <cite> <code> <ul> <ol> <li> <dl> <dt> <dd>
  • Zeilen und Absätze werden automatisch erzeugt.

Weitere Informationen über Formatierungsoptionen

Kommentar hinzufügen

Der Inhalt dieses Feldes wird nicht öffentlich zugänglich angezeigt.
  • Internet- und E-Mail-Adressen werden automatisch umgewandelt.
  • Zulässige HTML-Tags: <a> <em> <strong> <cite> <code> <ul> <ol> <li> <dl> <dt> <dd>
  • Zeilen und Absätze werden automatisch erzeugt.

Weitere Informationen über Formatierungsoptionen