shortcut_set_add_form

function shortcut_set_add_form

shortcut_set_add_form($form, &$form_state)

Form callback: builds the form for adding a shortcut set.

Parameters

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

$form_state: An associative array containing the current state of the form.

Return value

An array representing the form definition.

See also

shortcut_set_add_form_validate()

shortcut_set_add_form_submit()

Related topics

File

modules/shortcut/shortcut.admin.inc, line 208
Administrative page callbacks for the shortcut module.

Code

function shortcut_set_add_form($form, &$form_state) {
  $form['new'] = array(
    '#type' => 'textfield',
    '#title' => t('Set name'),
    '#description' => t('The new set is created by copying items from your default shortcut set.'),
    '#required' => TRUE,
  );

  $form['actions'] = array('#type' => 'actions');
  $form['actions']['submit'] = array(
    '#type' => 'submit',
    '#value' => t('Create new set'),
  );

  return $form;
}

© 2001–2016 by the original authors
Licensed under the GNU General Public License, version 2 and later.
Drupal is a registered trademark of Dries Buytaert.
https://api.drupal.org/api/drupal/modules!shortcut!shortcut.admin.inc/function/shortcut_set_add_form/7.x

在线笔记
App下载
App下载

扫描二维码

下载编程狮App

公众号
微信公众号

编程狮公众号

意见反馈
返回顶部