Overview

Namespaces

  • Budovy
  • Kdyby
    • BootstrapFormRenderer
      • DI
      • Latte
  • Nette
    • Application
      • Diagnostics
      • Responses
      • Routers
      • UI
    • Caching
      • Storages
    • ComponentModel
    • Database
      • Diagnostics
      • Drivers
      • Reflection
      • Table
    • DI
      • Config
        • Adapters
      • Diagnostics
      • Extensions
    • Diagnostics
    • Forms
      • Controls
      • Rendering
    • Http
      • Diagnostics
    • Iterators
    • Latte
      • Macros
    • Loaders
    • Localization
    • Mail
    • PhpGenerator
    • Reflection
    • Security
      • Diagnostics
    • Templating
    • Utils
  • NetteModule
  • Nextras
    • Datagrid
  • None
  • PHP
  • Tester
    • CodeCoverage
    • Runner
      • Output
  • Vodacek
    • Forms
      • Controls
  • WebLoader
    • Filter
    • Nette

Classes

  • BaseControl
  • Button
  • Checkbox
  • CheckboxList
  • ChoiceControl
  • CsrfProtection
  • HiddenField
  • ImageButton
  • MultiChoiceControl
  • MultiSelectBox
  • RadioList
  • SelectBox
  • SubmitButton
  • TextArea
  • TextBase
  • TextInput
  • UploadControl
  • Overview
  • Namespace
  • Class
  • Tree

Class TextBase

Implements the basic functionality common to text input controls.

Nette\Object
Extended by Nette\ComponentModel\Component implements Nette\ComponentModel\IComponent
Extended by Nette\Forms\Controls\BaseControl implements Nette\Forms\IControl
Extended by Nette\Forms\Controls\TextBase

Direct known subclasses

Nette\Forms\Controls\TextArea, Nette\Forms\Controls\TextInput
Abstract
Namespace: Nette\Forms\Controls
Author: David Grudl
Located at vendor/nette/nette/Nette/Forms/Controls/TextBase.php
Methods summary
public Nette\Forms\Controls\TextBase
# setValue( string $value )

Sets control's value.

Sets control's value.

Parameters

$value
string

Returns

Nette\Forms\Controls\TextBase

Overrides

Nette\Forms\Controls\BaseControl::setValue()
public string
# getValue( )

Returns control's value.

Returns control's value.

Returns

string

Overrides

Nette\Forms\Controls\BaseControl::getValue()
public Nette\Forms\Controls\TextBase
# setEmptyValue( string $value )

Sets the special value which is treated as empty string.

Sets the special value which is treated as empty string.

Parameters

$value
string

Returns

Nette\Forms\Controls\TextBase
public string
# getEmptyValue( )

Returns the special value which is treated as empty string.

Returns the special value which is treated as empty string.

Returns

string
public Nette\Forms\Controls\TextBase
# addFilter( callable $filter )

Appends input string filter callback.

Appends input string filter callback.

Parameters

$filter
callable

Returns

Nette\Forms\Controls\TextBase
public Nette\Utils\Html
# getControl( )

Generates control's HTML element.

Generates control's HTML element.

Returns

Nette\Utils\Html

Overrides

Nette\Forms\Controls\BaseControl::getControl()
public Nette\Forms\Controls\TextBase
# addRule( mixed $operation, string $message = NULL, mixed $arg = NULL )

Adds a validation rule.

Adds a validation rule.

Parameters

$operation
mixed
rule type
$message
string
message to display for invalid data
$arg
mixed
optional rule arguments

Returns

Nette\Forms\Controls\TextBase

Overrides

Nette\Forms\Controls\BaseControl::addRule()
public static boolean
# validateEmail( Nette\Forms\Controls\TextBase $control )

Email validator: is control's value valid email address?

Email validator: is control's value valid email address?

Parameters

$control
Nette\Forms\Controls\TextBase

Returns

boolean
public static boolean
# validateUrl( Nette\Forms\Controls\TextBase $control )

URL validator: is control's value valid URL?

URL validator: is control's value valid URL?

Parameters

$control
Nette\Forms\Controls\TextBase

Returns

boolean
public static string
# filterUrl( string $s )

URL string cleanup.

URL string cleanup.

Parameters

$s
string

Returns

string
public static boolean
# validatePattern( Nette\Forms\Controls\TextBase $control, string $pattern )

Regular expression validator: matches control's value regular expression?

Regular expression validator: matches control's value regular expression?

Parameters

$control
Nette\Forms\Controls\TextBase
$pattern
string

Returns

boolean
public static boolean
# validateInteger( Nette\Forms\Controls\TextBase $control )

Integer validator: is a control's value decimal number?

Integer validator: is a control's value decimal number?

Parameters

$control
Nette\Forms\Controls\TextBase

Returns

boolean
public static boolean
# validateFloat( Nette\Forms\Controls\TextBase $control )

Float validator: is a control's value float number?

Float validator: is a control's value float number?

Parameters

$control
Nette\Forms\Controls\TextBase

Returns

boolean
public static string
# filterFloat( string $s )

Float string cleanup.

Float string cleanup.

Parameters

$s
string

Returns

string
Methods inherited from Nette\Forms\Controls\BaseControl
__construct(), addCondition(), addConditionOn(), addError(), attached(), cleanErrors(), exportRules(), getControlPrototype(), getError(), getErrors(), getForm(), getHtmlId(), getHtmlName(), getHttpData(), getLabel(), getLabelPrototype(), getOption(), getOptions(), getRules(), getTranslator(), hasErrors(), isDisabled(), isFilled(), isOmitted(), isRequired(), loadHttpData(), setAttribute(), setDefaultValue(), setDisabled(), setHtmlId(), setOmitted(), setOption(), setRequired(), setTranslator(), translate(), validate(), validateBlank(), validateEqual(), validateFilled(), validateLength(), validateMaxLength(), validateMinLength(), validateNotEqual(), validateRange(), validateValid()
Methods inherited from Nette\ComponentModel\Component
__clone(), __sleep(), __wakeup(), detached(), getName(), getParent(), lookup(), lookupPath(), monitor(), unmonitor(), validateParent()
Methods inherited from Nette\Object
__call(), __callStatic(), __get(), __isset(), __set(), __unset(), extensionMethod(), getReflection()
Methods inherited from Nette\ComponentModel\IComponent
setParent()
Constants inherited from Nette\ComponentModel\IComponent
NAME_SEPARATOR
Properties summary
protected string $emptyValue ''
#
protected array $filters array()
#
protected mixed $rawValue ''
#

unfiltered submitted value

unfiltered submitted value

Properties inherited from Nette\Forms\Controls\BaseControl
$caption, $control, $disabled, $idMask, $label, $value
Magic properties summary
public string $emptyValue
#
Magic properties inherited from Nette\Forms\Controls\BaseControl
$control, $controlPrototype, $defaultValue, $disabled, $errors, $filled, $form, $htmlId, $htmlName, $label, $labelPrototype, $omitted, $options, $required, $rules, $translator, $value
Magic properties inherited from Nette\ComponentModel\Component
$name, $parent
Magic properties inherited from Nette\Object
$reflection
API documentation generated by ApiGen 2.8.0