image_style_add_form

Versions
mediamosa-21
image_style_add_form($form, &$form_state)

Form builder; Form for adding a new image style.

See also

image_style_add_form_submit()

@see image_style_name_validate()

Related topics

Code

modules/image/image.admin.inc, line 229

<?php
function image_style_add_form($form, &$form_state) {
  $form['name'] = array(
    '#type' => 'textfield',
    '#size' => '64',
    '#title' => t('Style name'),
    '#default_value' => '',
    '#description' => t('The name is used in URLs for generated images. Use only lowercase alphanumeric characters, underscores (_), and hyphens (-).'),
    '#element_validate' => array('image_style_name_validate'),
    '#required' => TRUE,
  );

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

  return $form;
}
?>