Dojo/Form/Element/Dijit.php

Show: inherited
Table of Contents

Zend Framework

LICENSE

This source file is subject to the new BSD license that is bundled with this package in the file LICENSE.txt. It is also available through the world-wide-web at this URL: http://framework.zend.com/license/new-bsd If you did not receive a copy of the license and are unable to obtain it through the world-wide-web, please send an email to [email protected] so we can send you a copy immediately.

Category
Zend  
Copyright
Copyright (c) 2005-2012 Zend Technologies USA Inc. (http://www.zend.com)  
License
New BSD License  
Package
Zend_Dojo  
Subpackage
Form_Element  

\Zend_Dojo_Form_Element_Dijit

Package: Zend\Dojo\Form\Element

Base element for dijit elements

Parent(s)
\Zend_Form_Element
Children
\Zend_Dojo_Form_Element_Editor
\Zend_Dojo_Form_Element_SimpleTextarea
\Zend_Dojo_Form_Element_TextBox
\Zend_Dojo_Form_Element_Button
\Zend_Dojo_Form_Element_DijitMulti
\Zend_Dojo_Form_Element_CheckBox
\Zend_Dojo_Form_Element_Slider
\Zend_Dojo_Form_Element_Textarea
Category
Zend  
Copyright
Copyright (c) 2005-2012 Zend Technologies USA Inc. (http://www.zend.com)  
License
New BSD License  
Version
$Id: Dijit.php 24593 2012-01-05 20:35:02Z matthew $  

Constants

Constant  DECORATOR = 'DECORATOR'
inherited

Element Constants

Inherited from: \Zend_Form_Element::DECORATOR
Inherited_from
\Zend_Form_Element::DECORATOR  
Constant  FILTER = 'FILTER'
inheritedInherited from: \Zend_Form_Element::FILTER
Inherited_from
\Zend_Form_Element::FILTER  
Constant  VALIDATE = 'VALIDATE'
inheritedInherited from: \Zend_Form_Element::VALIDATE
Inherited_from
\Zend_Form_Element::VALIDATE  

Properties

Propertyprotectedbool $_allowEmpty = true
inherited

'Allow empty' flag

Inherited from: \Zend_Form_Element::$$_allowEmpty
Default valuetrueDetails
Type
bool
Inherited_from
\Zend_Form_Element::$$_allowEmpty  
Propertyprotectedbool $_autoInsertNotEmptyValidator = true
inherited

Flag indicating whether or not to insert NotEmpty validator when element is required

Inherited from: \Zend_Form_Element::$$_autoInsertNotEmptyValidator
Default valuetrueDetails
Type
bool
Inherited_from
\Zend_Form_Element::$$_autoInsertNotEmptyValidator  
Propertyprotectedstring $_belongsTo =
inherited

Array to which element belongs

Inherited from: \Zend_Form_Element::$$_belongsTo
Details
Type
string
Inherited_from
\Zend_Form_Element::$$_belongsTo  
Propertyprotectedarray $_decorators = array()
inherited

Element decorators

Inherited from: \Zend_Form_Element::$$_decorators
Default valuearray()Details
Type
array
Inherited_from
\Zend_Form_Element::$$_decorators  
Propertyprotectedstring $_description =
inherited

Element description

Inherited from: \Zend_Form_Element::$$_description
Details
Type
string
Inherited_from
\Zend_Form_Element::$$_description  
Propertyprotectedbool $_disableLoadDefaultDecorators = false
inherited

Should we disable loading the default decorators?

Inherited from: \Zend_Form_Element::$$_disableLoadDefaultDecorators
Default valuefalseDetails
Type
bool
Inherited_from
\Zend_Form_Element::$$_disableLoadDefaultDecorators  
Propertyprotectedstring $_errorMessageSeparator = '; '
inherited

Separator to use when concatenating aggregate error messages (for elements having array values)

Inherited from: \Zend_Form_Element::$$_errorMessageSeparator
Default value'; 'Details
Type
string
Inherited_from
\Zend_Form_Element::$$_errorMessageSeparator  
Propertyprotectedarray $_errorMessages = array()
inherited

Custom error messages

Inherited from: \Zend_Form_Element::$$_errorMessages
Default valuearray()Details
Type
array
Inherited_from
\Zend_Form_Element::$$_errorMessages  
Propertyprotectedarray $_errors = array()
inherited

Validation errors

Inherited from: \Zend_Form_Element::$$_errors
Default valuearray()Details
Type
array
Inherited_from
\Zend_Form_Element::$$_errors  
Propertyprotectedarray $_filters = array()
inherited

Element filters

Inherited from: \Zend_Form_Element::$$_filters
Default valuearray()Details
Type
array
Inherited_from
\Zend_Form_Element::$$_filters  
Propertyprotectedbool $_ignore = false
inherited

Ignore flag (used when retrieving values at form level)

Inherited from: \Zend_Form_Element::$$_ignore
Default valuefalseDetails
Type
bool
Inherited_from
\Zend_Form_Element::$$_ignore  
Propertyprotectedbool $_isArray = false
inherited

Does the element represent an array?

Inherited from: \Zend_Form_Element::$$_isArray
Default valuefalseDetails
Type
bool
Inherited_from
\Zend_Form_Element::$$_isArray  
Propertyprotectedbool $_isError = false
inherited

Is the error marked as in an invalid state?

Inherited from: \Zend_Form_Element::$$_isError
Default valuefalseDetails
Type
bool
Inherited_from
\Zend_Form_Element::$$_isError  
Propertyprotectedbool $_isErrorForced = false
inherited

Has the element been manually marked as invalid?

Inherited from: \Zend_Form_Element::$$_isErrorForced
Default valuefalseDetails
Type
bool
Inherited_from
\Zend_Form_Element::$$_isErrorForced  
Propertyprotectedbool $_isPartialRendering = false
inherited

Is a specific decorator being rendered via the magic renderDecorator()?

Inherited from: \Zend_Form_Element::$$_isPartialRendering

This is to allow execution of logic inside the render() methods of child elements during the magic call while skipping the parent render() method.

Default valuefalseDetails
Type
bool
Inherited_from
\Zend_Form_Element::$$_isPartialRendering  
Propertyprotectedstring $_label =
inherited

Element label

Inherited from: \Zend_Form_Element::$$_label
Details
Type
string
Inherited_from
\Zend_Form_Element::$$_label  
Propertyprotectedarray $_loaders = array()
inherited

Plugin loaders for filter and validator chains

Inherited from: \Zend_Form_Element::$$_loaders
Default valuearray()Details
Type
array
Inherited_from
\Zend_Form_Element::$$_loaders  
Propertyprotectedarray $_messages = array()
inherited

Formatted validation error messages

Inherited from: \Zend_Form_Element::$$_messages
Default valuearray()Details
Type
array
Inherited_from
\Zend_Form_Element::$$_messages  
Propertyprotectedstring $_name =
inherited

Element name

Inherited from: \Zend_Form_Element::$$_name
Details
Type
string
Inherited_from
\Zend_Form_Element::$$_name  
Propertyprotectedint $_order =
inherited

Order of element

Inherited from: \Zend_Form_Element::$$_order
Details
Type
int
Inherited_from
\Zend_Form_Element::$$_order  
Propertyprotectedbool $_required = false
inherited

Required flag

Inherited from: \Zend_Form_Element::$$_required
Default valuefalseDetails
Type
bool
Inherited_from
\Zend_Form_Element::$$_required  
Propertyprotected\Zend_Translate $_translator =
inherited

Inherited from: \Zend_Form_Element::$$_translator
Details
Type
\Zend_Translate
Inherited_from
\Zend_Form_Element::$$_translator  
Propertyprotectedbool $_translatorDisabled = false
inherited

Is translation disabled?

Inherited from: \Zend_Form_Element::$$_translatorDisabled
Default valuefalseDetails
Type
bool
Inherited_from
\Zend_Form_Element::$$_translatorDisabled  
Propertyprotectedstring $_type =
inherited

Element type

Inherited from: \Zend_Form_Element::$$_type
Details
Type
string
Inherited_from
\Zend_Form_Element::$$_type  
Propertyprotectedarray $_validatorRules = array()
inherited

Array of un-initialized validators

Inherited from: \Zend_Form_Element::$$_validatorRules
Default valuearray()Details
Type
array
Inherited_from
\Zend_Form_Element::$$_validatorRules  
Propertyprotectedarray $_validators = array()
inherited

Array of initialized validators

<p>Validators</p>Inherited from: \Zend_Form_Element::$$_validators
Default valuearray()Details
Type
array
Inherited_from
\Zend_Form_Element::$$_validators  
Propertyprotectedmixed $_value =
inherited

Element value

Inherited from: \Zend_Form_Element::$$_value
Details
Type
mixed
Inherited_from
\Zend_Form_Element::$$_value  
Propertyprotected\Zend_View_Interface $_view =
inherited

Inherited from: \Zend_Form_Element::$$_view
Details
Type
\Zend_View_Interface
Inherited_from
\Zend_Form_Element::$$_view  
Propertypublicarray $dijitParams = array()

Dijit parameters

Default valuearray()Details
Type
array
Propertypublicstring $helper =

View helper to use

Details
Type
string

Methods

methodpublic__call(string $method, array $args) : string
inherited

Overloading: allow rendering specific decorators

Inherited from: \Zend_Form_Element::__call()

Call renderDecoratorName() to render a specific decorator.

Parameters
Name Type Description
$method string
$args array
Returns
Type Description
string
Throws
Exception Description
\Zend_Form_Exception for invalid decorator or invalid method call
methodpublic__construct(mixed $spec, mixed $options = null) : void

Constructor

$spec may be: - string: name of element - array: options with which to configure element - Zend_Config: Zend_Config with options for configuring element

Parameters
Name Type Description
$spec mixed
$options mixed
Throws
Exception Description
\Zend_Form_Exception if no element name after initialization
Details
Todo
Should we set dojo view helper paths here?  
methodpublic__get(string $key) : mixed
inherited

Overloading: retrieve object property

Inherited from: \Zend_Form_Element::__get()

Prevents access to properties beginning with '_'.

Parameters
Name Type Description
$key string
Returns
Type Description
mixed
methodpublic__set(string $key, mixed $value) : \voide
inherited

Overloading: set object property

Inherited from: \Zend_Form_Element::__set()
Parameters
Name Type Description
$key string
$value mixed
Returns
Type Description
\voide
methodpublic__toString() : string
inherited

String representation of form element

Inherited from: \Zend_Form_Element::__toString()

Proxies to render().

Returns
Type Description
string
methodprotected_filterValue(string $value, string $key) : void
inherited

Filter a value

Inherited from: \Zend_Form_Element::_filterValue()
Parameters
Name Type Description
$value string
$key string
methodprotected_getDecorator(string $name, null | array $options) : \Zend_Form_Decorator_Interface
inherited

Instantiate a decorator based on class name or class name fragment

Inherited from: \Zend_Form_Element::_getDecorator()
Parameters
Name Type Description
$name string
$options null | array
Returns
Type Description
\Zend_Form_Decorator_Interface
methodprotected_getErrorMessages() : array
inherited

Retrieve error messages and perform translation and value substitution

Inherited from: \Zend_Form_Element::_getErrorMessages()
Returns
Type Description
array
methodprotected_hasErrorMessages() : bool
inherited

Are there custom error messages registered?

Inherited from: \Zend_Form_Element::_hasErrorMessages()
Returns
Type Description
bool
methodprotected_loadDecorator(array $decorator, mixed $name) : \Zend_Form_Decorator_Interface
inherited

Lazy-load a decorator

Inherited from: \Zend_Form_Element::_loadDecorator()
Parameters
Name Type Description
$decorator array

Decorator type and options

$name mixed

Decorator name or alias

Returns
Type Description
\Zend_Form_Decorator_Interface
methodprotected_loadFilter(array $filter) : \Zend_Filter_Interface
inherited

Lazy-load a filter

Inherited from: \Zend_Form_Element::_loadFilter()
Parameters
Name Type Description
$filter array
Returns
Type Description
\Zend_Filter_Interface
methodprotected_loadValidator(array $validator) : \Zend_Validate_Interface
inherited

Lazy-load a validator

Inherited from: \Zend_Form_Element::_loadValidator()
Parameters
Name Type Description
$validator array

Validator definition

Returns
Type Description
\Zend_Validate_Interface
methodpublicaddDecorator(string | \Zend_Form_Decorator_Interface $decorator, array | \Zend_Config $options = null) : \Zend_Form_Element
inherited

Add a decorator for rendering the element

Inherited from: \Zend_Form_Element::addDecorator()
Parameters
Name Type Description
$decorator string | \Zend_Form_Decorator_Interface
$options array | \Zend_Config

Options with which to initialize decorator

Returns
Type Description
\Zend_Form_Element
methodpublicaddDecorators(array $decorators) : \Zend_Form_Element
inherited

Add many decorators at once

Inherited from: \Zend_Form_Element::addDecorators()
Parameters
Name Type Description
$decorators array
Returns
Type Description
\Zend_Form_Element
methodpublicaddError(string $message) : \Zend_Form_Element
inherited

Add an error message and mark element as failed validation

Inherited from: \Zend_Form_Element::addError()
Parameters
Name Type Description
$message string
Returns
Type Description
\Zend_Form_Element
methodpublicaddErrorMessage(string $message) : \Zend_Form_Element
inherited

Add a custom error message to return in the event of failed validation

Inherited from: \Zend_Form_Element::addErrorMessage()
Parameters
Name Type Description
$message string
Returns
Type Description
\Zend_Form_Element
methodpublicaddErrorMessages(array $messages) : \Zend_Form_Element
inherited

Add multiple custom error messages to return in the event of failed validation

Inherited from: \Zend_Form_Element::addErrorMessages()
Parameters
Name Type Description
$messages array
Returns
Type Description
\Zend_Form_Element
methodpublicaddErrors(array $messages) : \Zend_Form_Element
inherited

Add multiple error messages and flag element as failed validation

Inherited from: \Zend_Form_Element::addErrors()
Parameters
Name Type Description
$messages array
Returns
Type Description
\Zend_Form_Element
methodpublicaddFilter(string | \Zend_Filter_Interface $filter,  $options = array()) : \Zend_Form_Element
inherited

Add a filter to the element

Inherited from: \Zend_Form_Element::addFilter()
Parameters
Name Type Description
$filter string | \Zend_Filter_Interface
$options
Returns
Type Description
\Zend_Form_Element
methodpublicaddFilters(array $filters) : \Zend_Form_Element
inherited

Add filters to element

Inherited from: \Zend_Form_Element::addFilters()
Parameters
Name Type Description
$filters array
Returns
Type Description
\Zend_Form_Element
methodpublicaddPrefixPath(string $prefix, string $path, string $type = null) : \Zend_Form_Element
inherited

Add prefix path for plugin loader

Inherited from: \Zend_Form_Element::addPrefixPath()

If no $type specified, assumes it is a base path for both filters and validators, and sets each according to the following rules: - decorators: $prefix = $prefix . '_Decorator' - filters: $prefix = $prefix . '_Filter' - validators: $prefix = $prefix . '_Validate'

Otherwise, the path prefix is set on the appropriate plugin loader.

Parameters
Name Type Description
$prefix string
$path string
$type string
Returns
Type Description
\Zend_Form_Element
Throws
Exception Description
\Zend_Form_Exception for invalid type
methodpublicaddPrefixPaths(array $spec) : \Zend_Form_Element
inherited

Add many prefix paths at once

Inherited from: \Zend_Form_Element::addPrefixPaths()
Parameters
Name Type Description
$spec array
Returns
Type Description
\Zend_Form_Element
methodpublicaddValidator(string | \Zend_Validate_Interface $validator, bool $breakChainOnFailure = false, array $options = array()) : \Zend_Form_Element
inherited

Add validator to validation chain

Inherited from: \Zend_Form_Element::addValidator()

Note: will overwrite existing validators if they are of the same class.

Parameters
Name Type Description
$validator string | \Zend_Validate_Interface
$breakChainOnFailure bool
$options array
Returns
Type Description
\Zend_Form_Element
Throws
Exception Description
\Zend_Form_Exception if invalid validator type
methodpublicaddValidators(array $validators) : \Zend_Form_Element
inherited

Add multiple validators

Inherited from: \Zend_Form_Element::addValidators()
Parameters
Name Type Description
$validators array
Returns
Type Description
\Zend_Form_Element
methodpublicautoInsertNotEmptyValidator() : bool
inherited

Get flag indicating whether a NotEmpty validator should be inserted when element is required

Inherited from: \Zend_Form_Element::autoInsertNotEmptyValidator()
Returns
Type Description
bool
methodpublicclearDecorators() : \Zend_Form_Element
inherited

Clear all decorators

Inherited from: \Zend_Form_Element::clearDecorators()
Returns
Type Description
\Zend_Form_Element
methodpublicclearDijitParams() : \Zend_Dojo_Form_Element_Dijit

Clear all dijit parameters

Returns
Type Description
\Zend_Dojo_Form_Element_Dijit
methodpublicclearErrorMessages() : \Zend_Form_Element
inherited

Clear custom error messages stack

Inherited from: \Zend_Form_Element::clearErrorMessages()
Returns
Type Description
\Zend_Form_Element
methodpublicclearFilters() : \Zend_Form_Element
inherited

Clear all filters

Inherited from: \Zend_Form_Element::clearFilters()
Returns
Type Description
\Zend_Form_Element
methodpublicclearValidators() : \Zend_Form_Element
inherited

Clear all validators

Inherited from: \Zend_Form_Element::clearValidators()
Returns
Type Description
\Zend_Form_Element
methodpublicfilterName(string $value, bool $allowBrackets = false) : string
inherited

Filter a name to only allow valid variable characters

Inherited from: \Zend_Form_Element::filterName()
Parameters
Name Type Description
$value string
$allowBrackets bool
Returns
Type Description
string
methodpublicgetAllowEmpty() : bool
inherited

Get 'allow empty' flag

Inherited from: \Zend_Form_Element::getAllowEmpty()
Returns
Type Description
bool
methodpublicgetAttrib(string $name) : string
inherited

Retrieve element attribute

Inherited from: \Zend_Form_Element::getAttrib()
Parameters
Name Type Description
$name string
Returns
Type Description
string
methodpublicgetAttribs() : array
inherited

Return all attributes

Inherited from: \Zend_Form_Element::getAttribs()
Returns
Type Description
array
methodpublicgetBelongsTo() : string
inherited

Return array name to which element belongs

Inherited from: \Zend_Form_Element::getBelongsTo()
Returns
Type Description
string
methodpublicgetDecorator(string $name) : false | \Zend_Form_Decorator_Abstract
inherited

Retrieve a registered decorator

Inherited from: \Zend_Form_Element::getDecorator()
Parameters
Name Type Description
$name string
Returns
Type Description
false | \Zend_Form_Decorator_Abstract
methodpublicgetDecorators() : array
inherited

Retrieve all decorators

Inherited from: \Zend_Form_Element::getDecorators()
Returns
Type Description
array
methodpublicgetDescription() : string
inherited

Retrieve element description

Inherited from: \Zend_Form_Element::getDescription()
Returns
Type Description
string
methodpublicgetDijitParam(string $key) : mixed

Get a single dijit parameter

Parameters
Name Type Description
$key string
Returns
Type Description
mixed
methodpublicgetDijitParams() : array

Retrieve all dijit parameters

Returns
Type Description
array
methodpublicgetErrorMessageSeparator() : string
inherited

Get errorMessageSeparator

Inherited from: \Zend_Form_Element::getErrorMessageSeparator()
Returns
Type Description
string
methodpublicgetErrorMessages() : array
inherited

Retrieve custom error messages

Inherited from: \Zend_Form_Element::getErrorMessages()
Returns
Type Description
array
methodpublicgetErrors() : array
inherited

Retrieve validator chain errors

Inherited from: \Zend_Form_Element::getErrors()
Returns
Type Description
array
methodpublicgetFilter(string $name) : \Zend_Filter_Interface
inherited

Retrieve a single filter by name

Inherited from: \Zend_Form_Element::getFilter()
Parameters
Name Type Description
$name string
Returns
Type Description
\Zend_Filter_Interface
methodpublicgetFilters() : array
inherited

Get all filters

Inherited from: \Zend_Form_Element::getFilters()
Returns
Type Description
array
methodpublicgetFullyQualifiedName() : string
inherited

Get fully qualified name

Inherited from: \Zend_Form_Element::getFullyQualifiedName()

Places name as subitem of array and/or appends brackets.

Returns
Type Description
string
methodpublicgetId() : string
inherited

Get element id

Inherited from: \Zend_Form_Element::getId()
Returns
Type Description
string
methodpublicgetIgnore() : bool
inherited

Get ignore flag (used when retrieving values at form level)

Inherited from: \Zend_Form_Element::getIgnore()
Returns
Type Description
bool
methodpublicgetLabel() : string
inherited

Retrieve element label

Inherited from: \Zend_Form_Element::getLabel()
Returns
Type Description
string
methodpublicgetMessages() : array
inherited

Retrieve error messages

Inherited from: \Zend_Form_Element::getMessages()

The array keys are validation failure message identifiers, and the array values are the corresponding human-readable message strings.

If isValid() was never called or if the most recent isValid() call returned true, then this method returns an empty array.

Returns
Type Description
array
methodpublicgetName() : string
inherited

Return element name

Inherited from: \Zend_Form_Element::getName()
Returns
Type Description
string
methodpublicgetOrder() : int
inherited

Retrieve element order

Inherited from: \Zend_Form_Element::getOrder()
Returns
Type Description
int
methodpublicgetPluginLoader(string $type) : \Zend_Loader_PluginLoader
inherited

Retrieve plugin loader for validator or filter chain

Inherited from: \Zend_Form_Element::getPluginLoader()

Instantiates with default rules if none available for that type. Use 'decorator', 'filter', or 'validate' for $type.

Parameters
Name Type Description
$type string
Returns
Type Description
\Zend_Loader_PluginLoader
Throws
Exception Description
\Zend_Loader_Exception on invalid type.
methodpublicgetTranslator() : \Zend_Translate_Adapter | null
inherited

Retrieve localization translator object

Inherited from: \Zend_Form_Element::getTranslator()
Returns
Type Description
\Zend_Translate_Adapter | null
methodpublicgetType() : string
inherited

Return element type

Inherited from: \Zend_Form_Element::getType()
Returns
Type Description
string
methodpublicgetUnfilteredValue() : mixed
inherited

Retrieve unfiltered element value

Inherited from: \Zend_Form_Element::getUnfilteredValue()
Returns
Type Description
mixed
methodpublicgetValidator(string $name) : \Zend_Validate_Interface | false
inherited

Retrieve a single validator by name

Inherited from: \Zend_Form_Element::getValidator()
Parameters
Name Type Description
$name string
Returns
Type Description
\Zend_Validate_Interface | false False if not found, validator otherwise
methodpublicgetValidators() : array
inherited

Retrieve all validators

Inherited from: \Zend_Form_Element::getValidators()
Returns
Type Description
array
methodpublicgetValue() : mixed
inherited

Retrieve filtered element value

Inherited from: \Zend_Form_Element::getValue()
Returns
Type Description
mixed
methodpublicgetView() : null | \Zend_View_Interface
inherited

Retrieve view object

Inherited from: \Zend_Form_Element::getView()

Retrieves from ViewRenderer if none previously set.

Returns
Type Description
null | \Zend_View_Interface
methodpublichasDijitParam(string $key) : bool

Does the given dijit parameter exist?

Parameters
Name Type Description
$key string
Returns
Type Description
bool
methodpublichasErrors() : bool
inherited

Are there errors registered?

Inherited from: \Zend_Form_Element::hasErrors()
Returns
Type Description
bool
methodpublichasTranslator() : bool
inherited

Does this element have its own specific translator?

Inherited from: \Zend_Form_Element::hasTranslator()
Returns
Type Description
bool
methodpublicinit() : void
inherited

Initialize object; used by extending classes

Inherited from: \Zend_Form_Element::init()
methodpublicisArray() : bool
inherited

Is the element representing an array?

Inherited from: \Zend_Form_Element::isArray()
Returns
Type Description
bool
methodpublicisRequired() : bool
inherited

Is the element required?

Inherited from: \Zend_Form_Element::isRequired()
Returns
Type Description
bool
methodpublicisValid(mixed $value, mixed $context = null) : boolean
inherited

Validate element value

Inherited from: \Zend_Form_Element::isValid()

If a translation adapter is registered, any error messages will be translated according to the current locale, using the given error code; if no matching translation is found, the original message will be utilized.

Note: The filtered value is validated.

Parameters
Name Type Description
$value mixed
$context mixed
Returns
Type Description
boolean
Throws
Exception Description
\Zend_Validate_Exception If validation of $value is impossible
methodpublicloadDefaultDecorators() : void

Load default decorators

methodpublicloadDefaultDecoratorsIsDisabled() : bool
inherited

Should we load the default decorators?

Inherited from: \Zend_Form_Element::loadDefaultDecoratorsIsDisabled()
Returns
Type Description
bool
methodpublicmarkAsError() : \Zend_Form_Element
inherited

Mark the element as being in a failed validation state

Inherited from: \Zend_Form_Element::markAsError()
Returns
Type Description
\Zend_Form_Element
methodpublicremoveDecorator(string $name) : \Zend_Form_Element
inherited

Remove a single decorator

Inherited from: \Zend_Form_Element::removeDecorator()
Parameters
Name Type Description
$name string
Returns
Type Description
\Zend_Form_Element
methodpublicremoveDijitParam(string $key) : \Zend_Dojo_Form_Element_Dijit

Remove a single dijit parameter

Parameters
Name Type Description
$key string
Returns
Type Description
\Zend_Dojo_Form_Element_Dijit
methodpublicremoveFilter(string $name) : \Zend_Form_Element
inherited

Remove a filter by name

Inherited from: \Zend_Form_Element::removeFilter()
Parameters
Name Type Description
$name string
Returns
Type Description
\Zend_Form_Element
methodpublicremoveValidator(string $name) : bool
inherited

Remove a single validator by name

Inherited from: \Zend_Form_Element::removeValidator()
Parameters
Name Type Description
$name string
Returns
Type Description
bool
methodpublicrender(\Zend_View_Interface $view = null) : string
inherited

Render form element

Inherited from: \Zend_Form_Element::render()
Parameters
Name Type Description
$view \Zend_View_Interface
Returns
Type Description
string
methodpublicresolveElementId(\Zend_Form_Decorator_Interface $decorator) : string
staticinherited

Used to resolve and return an element ID

Inherited from: \Zend_Form_Element::resolveElementId()

Passed to the HtmlTag decorator as a callback in order to provide an ID.

Parameters
Name Type Description
$decorator \Zend_Form_Decorator_Interface
Returns
Type Description
string
methodpublicsetAllowEmpty(bool $flag) : \Zend_Form_Element
inherited

Set 'allow empty' flag

Inherited from: \Zend_Form_Element::setAllowEmpty()

When the allow empty flag is enabled and the required flag is false, the element will validate with empty values.

Parameters
Name Type Description
$flag bool
Returns
Type Description
\Zend_Form_Element
methodpublicsetAttrib(string $name, mixed $value) : \Zend_Form_Element
inherited

Set element attribute

Inherited from: \Zend_Form_Element::setAttrib()
Parameters
Name Type Description
$name string
$value mixed
Returns
Type Description
\Zend_Form_Element
Throws
Exception Description
\Zend_Form_Exception for invalid $name values
methodpublicsetAttribs(array $attribs) : \Zend_Form_Element
inherited

Set multiple attributes at once

Inherited from: \Zend_Form_Element::setAttribs()
Parameters
Name Type Description
$attribs array
Returns
Type Description
\Zend_Form_Element
methodpublicsetAutoInsertNotEmptyValidator(bool $flag) : \Zend_Form_Element
inherited

Set flag indicating whether a NotEmpty validator should be inserted when element is required

Inherited from: \Zend_Form_Element::setAutoInsertNotEmptyValidator()
Parameters
Name Type Description
$flag bool
Returns
Type Description
\Zend_Form_Element
methodpublicsetBelongsTo(string $array) : \Zend_Form_Element
inherited

Set array to which element belongs

Inherited from: \Zend_Form_Element::setBelongsTo()
Parameters
Name Type Description
$array string
Returns
Type Description
\Zend_Form_Element
methodpublicsetConfig(\Zend_Config $config) : \Zend_Form_Element
inherited

Set object state from Zend_Config object

Inherited from: \Zend_Form_Element::setConfig()
Parameters
Name Type Description
$config \Zend_Config
Returns
Type Description
\Zend_Form_Element
methodpublicsetDecorators(array $decorators) : \Zend_Form_Element
inherited

Overwrite all decorators

Inherited from: \Zend_Form_Element::setDecorators()
Parameters
Name Type Description
$decorators array
Returns
Type Description
\Zend_Form_Element
methodpublicsetDescription(string $description) : \Zend_Form_Element
inherited

Set element description

Inherited from: \Zend_Form_Element::setDescription()
Parameters
Name Type Description
$description string
Returns
Type Description
\Zend_Form_Element
methodpublicsetDijitParam(string $key, mixed $value) : \Zend_Dojo_Form_Element_Dijit

Set a dijit parameter

Parameters
Name Type Description
$key string
$value mixed
Returns
Type Description
\Zend_Dojo_Form_Element_Dijit
methodpublicsetDijitParams(array $params) : \Zend_Dojo_Form_Element_Dijit

Set multiple dijit params at once

Parameters
Name Type Description
$params array
Returns
Type Description
\Zend_Dojo_Form_Element_Dijit
methodpublicsetDisableLoadDefaultDecorators(bool $flag) : \Zend_Form_Element
inherited

Set flag to disable loading default decorators

Inherited from: \Zend_Form_Element::setDisableLoadDefaultDecorators()
Parameters
Name Type Description
$flag bool
Returns
Type Description
\Zend_Form_Element
methodpublicsetDisableTranslator(bool $flag) : \Zend_Form_Element
inherited

Indicate whether or not translation should be disabled

Inherited from: \Zend_Form_Element::setDisableTranslator()
Parameters
Name Type Description
$flag bool
Returns
Type Description
\Zend_Form_Element
methodpublicsetErrorMessageSeparator(string $separator) : \Zend_Form_Element
inherited

Set errorMessageSeparator

Inherited from: \Zend_Form_Element::setErrorMessageSeparator()
Parameters
Name Type Description
$separator string
Returns
Type Description
\Zend_Form_Element
methodpublicsetErrorMessages(array $messages) : \Zend_Form_Element
inherited

Same as addErrorMessages(), but clears custom error message stack first

Inherited from: \Zend_Form_Element::setErrorMessages()
Parameters
Name Type Description
$messages array
Returns
Type Description
\Zend_Form_Element
methodpublicsetErrors(array $messages) : \Zend_Form_Element
inherited

Overwrite any previously set error messages and flag as failed validation

Inherited from: \Zend_Form_Element::setErrors()
Parameters
Name Type Description
$messages array
Returns
Type Description
\Zend_Form_Element
methodpublicsetFilters(array $filters) : \Zend_Form_Element
inherited

Add filters to element, overwriting any already existing

Inherited from: \Zend_Form_Element::setFilters()
Parameters
Name Type Description
$filters array
Returns
Type Description
\Zend_Form_Element
methodpublicsetIgnore(bool $flag) : \Zend_Form_Element
inherited

Set ignore flag (used when retrieving values at form level)

Inherited from: \Zend_Form_Element::setIgnore()
Parameters
Name Type Description
$flag bool
Returns
Type Description
\Zend_Form_Element
methodpublicsetIsArray(bool $flag) : \Zend_Form_Element
inherited

Set flag indicating if element represents an array

Inherited from: \Zend_Form_Element::setIsArray()
Parameters
Name Type Description
$flag bool
Returns
Type Description
\Zend_Form_Element
methodpublicsetLabel(string $label) : \Zend_Form_Element
inherited

Set element label

Inherited from: \Zend_Form_Element::setLabel()
Parameters
Name Type Description
$label string
Returns
Type Description
\Zend_Form_Element
methodpublicsetName(string $name) : \Zend_Form_Element
inherited

Set element name

Inherited from: \Zend_Form_Element::setName()
Parameters
Name Type Description
$name string
Returns
Type Description
\Zend_Form_Element
methodpublicsetOptions(array $options) : \Zend_Form_Element
inherited

Set object state from options array

Inherited from: \Zend_Form_Element::setOptions()
Parameters
Name Type Description
$options array
Returns
Type Description
\Zend_Form_Element
methodpublicsetOrder(int $order) : \Zend_Form_Element
inherited

Set element order

Inherited from: \Zend_Form_Element::setOrder()
Parameters
Name Type Description
$order int
Returns
Type Description
\Zend_Form_Element
methodpublicsetPluginLoader(\Zend_Loader_PluginLoader_Interface $loader, string $type) : \Zend_Form_Element
inherited

Set plugin loader to use for validator or filter chain

Inherited from: \Zend_Form_Element::setPluginLoader()
Parameters
Name Type Description
$loader \Zend_Loader_PluginLoader_Interface
$type string

'decorator', 'filter', or 'validate'

Returns
Type Description
\Zend_Form_Element
Throws
Exception Description
\Zend_Form_Exception on invalid type
methodpublicsetRequired(bool $flag = true) : \Zend_Form_Element
inherited

Set required flag

Inherited from: \Zend_Form_Element::setRequired()
Parameters
Name Type Description
$flag bool

Default value is true

Returns
Type Description
\Zend_Form_Element
methodpublicsetTranslator(\Zend_Translate | null $translator = null) : \Zend_Form_Element
inherited

Set translator object for localization

Inherited from: \Zend_Form_Element::setTranslator()
Parameters
Name Type Description
$translator \Zend_Translate | null
Returns
Type Description
\Zend_Form_Element
methodpublicsetValidators(array $validators) : \Zend_Form_Element
inherited

Set multiple validators, overwriting previous validators

Inherited from: \Zend_Form_Element::setValidators()
Parameters
Name Type Description
$validators array
Returns
Type Description
\Zend_Form_Element
methodpublicsetValue(mixed $value) : \Zend_Form_Element
inherited

Set element value

Inherited from: \Zend_Form_Element::setValue()
Parameters
Name Type Description
$value mixed
Returns
Type Description
\Zend_Form_Element
methodpublicsetView(\Zend_View_Interface $view = null) : \Zend_Dojo_Form_Element_Dijit

Set the view object

Ensures that the view object has the dojo view helper path set.

Parameters
Name Type Description
$view \Zend_View_Interface
Returns
Type Description
\Zend_Dojo_Form_Element_Dijit
methodpublictranslatorIsDisabled() : bool
inherited

Is translation disabled?

Inherited from: \Zend_Form_Element::translatorIsDisabled()
Returns
Type Description
bool
Documentation was generated by phpDocumentor 2.0.0a8.