You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 

30 lines
782 B

  1. <?php
  2. /**
  3. * Class helper_plugin_bureaucracy_fieldtextarea
  4. *
  5. * Creates a multi-line input field
  6. */
  7. class helper_plugin_bureaucracy_fieldtextarea extends helper_plugin_bureaucracy_field {
  8. /**
  9. * Arguments:
  10. * - cmd
  11. * - label
  12. * - x123 (optional) as number of lines
  13. * - ^ (optional)
  14. */
  15. public function initialize($args) {
  16. parent::initialize($args);
  17. if (!isset($this->opt['class'])) {
  18. $this->opt['class'] = '';
  19. }
  20. $this->opt['class'] .= ' textareafield';
  21. }
  22. protected $tpl =
  23. '<label class="@@CLASS@@">
  24. <span>@@DISPLAY@@</span>
  25. <textarea name="@@NAME@@" id="@@ID@@" rows="@@ROWS|10@@" cols="10" class="edit @@OPTIONAL|required" required="required@@">@@VALUE@@</textarea>
  26. </label>';
  27. }