Krang::ElementClass::TextInputList - a manageable list of text input fields


   $class = pkg('ElementClass::TextInputList')->new(
        name => "keywords",
        maxlength => 10,
        size      => 12,
        defaults  => 3,  # create three empty input fields in the list
   $class = pkg('ElementClass::TextInputList')->new(
        name          => "unordered_list",
        bulk_edit     => 'xinha',
        bulk_edit_tag => 'ul',


This element provides a list of one or more text input fields that can be added, deleted and moved up and down.

It may be used to represent HTML ordered and unordered lists, each list item being represented by one text input field. This also provides for more orthogonality with Xinha-based bulk editing. Un(ordered) lists edited in Xinha bulk edit can be mapped to a TextInputList element as shown in the SYNOPSIS. Indeed, 'ul' and 'ol' are the only supported values for bulk_edit_tag

Another use-case would be a list of keywords, also shown in the SYNOPSIS. Textarea-based bulk-editing is currently not supported.

The data slot holds an arrayref of the list element values.

fill_template() generates a tmpl_loop whose naming convention is best explained with an example.

   $class = pkg('ElementClass::TextInputList')->new(
        name => "keywords",


   <tmpl_loop keywords_loop>
     <tmpl_var keywords_item>

appending '_loop' resp. '_item' to the element's name.


All the normal Krang::ElementClass attributes are available.