---
name: "HTML::FormHandler::Field::Text"
section: "3pm"
platform: "linux"
package: "libhtml-formhandler-perl"
version: "0.40068-2"
release: "Debian 13 (Trixie)"
platforms: ["linux"]
url: "https://new.carta.tech/HTML::FormHandler::Field::Text"
---

# HTML::FormHandler::Field::Text(3pm)

text field

## NAME

HTML::FormHandler::Field::Text - text field

## VERSION

version 0.40068

## DESCRIPTION

This is a simple text entry field. Widget type is 'text'.

## METHODS

### size \[integer\]

This is used in constructing HTML. It determines the size of the input field. The 'maxlength' field should be used as a constraint on the size of the field, not this attribute.

### minlength \[integer\]

This integer value, if non-zero, defines the minimum number of characters that must be entered.

### maxlength \[integer\]

A constraint on the maximum length of the text.

### error messages

Set error messages (text\_minlength, text\_maxlength):

```
    has_field 'my_text' => ( type => 'Text', messages =>
        {  'text_minlength' => 'Field is too short',
           'text_maxlength' => 'Field is too long',
        } );
```

## AUTHOR

FormHandler Contributors - see HTML::FormHandler

## COPYRIGHT AND LICENSE

This software is copyright (c) 2017 by Gerda Shank.

This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.
