Class TextInput (namespace Nette\Forms)


Single line text input control.

Object
   |
   --Component
      |
      --FormControl
         |
         --TextBase
            |
            --TextInput
Copyright: Copyright (c) 2004, 2010 David Grudl
Located: in /Forms/Controls/TextInput.php (line 21)
Public Method Summary
TextInput
__construct ([string $label = NULL], [string $cols = NULL], [int $maxLength = NULL], int 3)
string
checkMaxLength ($value)
Filter: shortens value to control's max length.
Html
Generates control's HTML element.
void
notifyRule (Rule $rule)
TextInput
setPasswordMode ([bool $mode = TRUE])
Sets or unsets the password mode.
Methods Inherited From TextBase
addFilter(), filterFloat(), getEmptyValue(), getValue(), notifyRule(), setEmptyValue(), setValue(), validateEmail(), validateFloat(), validateInteger(), validateLength(), validateMaxLength(), validateMinLength(), validateRange(), validateRegexp(), validateUrl()
Methods Inherited From FormControl
__construct(), addCondition(), addConditionOn(), addError(), addRule(), attached(), cleanErrors(), getControl(), getControlPrototype(), getErrors(), getForm(), getHtmlId(), getHtmlName(), getLabel(), getLabelPrototype(), getOption(), getOptions(), getRules(), getTranslator(), getValue(), hasErrors(), isDisabled(), isRendered(), isRequired(), loadHttpData(), notifyRule(), setDefaultValue(), setDisabled(), setHtmlId(), setOption(), setRendered(), setRequired(), setTranslator(), setValue(), translate(), validateEqual(), validateFilled(), validateValid()
Methods Inherited From Component
__construct(), attached(), detached(), getName(), getParent(), lookup(), lookupPath(), monitor(), setParent(), unmonitor(), validateParent(), __clone(), __wakeup()
Methods Inherited From Object
extensionMethod(), getClass(), getReflection(), __call(), __callStatic(), __get(), __isset(), __set(), __unset()
Variable Summary

Method Details

line 30

__construct

public TextInput __construct ([string $label = NULL], [string $cols = NULL], [int $maxLength = NULL], int 3)

Input
string $label control name
string $cols label
int $maxLength width of the control
int 3 maximum number of characters the user may enter
Output
TextInput  

line 47

checkMaxLength

public string checkMaxLength ($value)

Filter: shortens value to control's max length.

Input
$value
Output
string  

line 74

getControl

public Html getControl ()

Generates control's HTML element.

Output
Html  

line 85

notifyRule

public void notifyRule (Rule $rule)

Input
Rule $rule
Output
void  

line 62

setPasswordMode

public TextInput setPasswordMode ([bool $mode = TRUE])

Sets or unsets the password mode.

Input
bool $mode
Output
TextInput provides a fluent interface