You are here

public function boxes_i18n::options_form in Boxes translation 7

Same name and namespace in other branches
  1. 6 plugins/boxes/boxes_i18n.inc \boxes_i18n::options_form()

Implements boxes_content::options_form().

Overrides boxes_simple::options_form

File

plugins/boxes/boxes_i18n.inc, line 23

Class

boxes_i18n
Simple translatable custom text box.

Code

public function options_form(&$form_state) {
  $form = parent::options_form($form_state);
  $form['i18n_boxes'] = array(
    '#type' => 'fieldset',
    '#title' => t('Multilingual settings'),
    '#collapsible' => TRUE,
    '#weight' => 0,
    '#tree' => TRUE,
  );
  $options = array(
    '' => t('All languages'),
  );
  $options[I18N_BOXES_LOCALIZE] = t('All languages (Translatable)');
  $options += locale_language_list('name');
  $form['i18n_boxes']['language'] = array(
    '#type' => 'radios',
    '#title' => t('Language'),
    '#default_value' => $this->options['i18n_boxes']['language'],
    '#options' => $options,
  );
  return $form;
}