API Documentation

View/Helper/FormErrors.php

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 license@zend.com so we can send you a copy immediately.

category
Zend  
copyright
Copyright (c) 2005-2011 Zend Technologies USA Inc. (http://www.zend.com)  
license
New BSD License  
package
Zend_View  
subpackage
Helper  
version
$Id: FormErrors.php 23775 2011-03-01 17:25:24Z ralph $  

\Zend_View_Helper_FormErrors

Helper to render errors for a form element

Extends from
\Zend_View_Helper_FormElement
category
Zend  
copyright
Copyright (c) 2005-2011 Zend Technologies USA Inc. (http://www.zend.com)  
license
New BSD License  
package
Zend_View  
subpackage
Helper  

Properties

Propertyprotected\Zend_Form_Element  $_element= ''

Details
Type
\Zend_Form_Element
Propertyprotected  $_htmlElementEnd= '</li></ul>'
Default value</li></ul>Details
Type
Propertyprotected  $_htmlElementSeparator= '</li><li>'
Default value</li><li>Details
Type
Propertyprotected  $_htmlElementStart= '<ul%s><li>'
Default value<ul%s><li>Details
Type

Methods

methodprotected_getInfo(  $name,  $value = null,  $attribs = null,  $options = null,  $listsep = null ) : array

Converts parameter arguments to an element info array.

Inherited from: \Zend_View_Helper_FormElement::_getInfo()

E.g, formExample($name, $value, $attribs, $options, $listsep) is the same thing as formExample(array('name' => ...)).

Note that you cannot pass a 'disable' param; you need to pass it as an 'attribs' key.

Parameters
Name Type Description
$name
$value
$attribs
$options
$listsep
Returns
Type Description
array An element info array with keys for name, value, attribs, options, listsep, disable, and escape.
Details
access
protected  
methodprotected_hidden( string $name, string $value = null, array $attribs = null ) : string

Creates a hidden element.

Inherited from: \Zend_View_Helper_FormElement::_hidden()

We have this as a common method because other elements often need hidden elements for their operation.

Parameters
Name Type Description
$name string The element name.
$value string The element value.
$attribs array Attributes for the element.
Returns
Type Description
string A hidden element.
Details
access
protected  
methodprotected_htmlAttribs( array $attribs ) : string

Converts an associative array to a string of tag attributes.

Inherited from: \Zend_View_Helper_HtmlElement::_htmlAttribs()
Parameters
Name Type Description
$attribs array

From this array, each key-value pair is converted to an attribute name and value.

Returns
Type Description
string The XHTML for the attributes.
Details
access
public  
methodprotected_isStrictDoctype( ) : boolean

Is doctype strict?

Inherited from: \Zend_View_Helper_HtmlElement::_isStrictDoctype()
Returns
Type Description
boolean
methodprotected_isXhtml( ) : boolean

Is doctype XHTML?

Inherited from: \Zend_View_Helper_HtmlElement::_isXhtml()
Returns
Type Description
boolean
methodprotected_normalizeId( string $value ) : string

Normalize an ID

Inherited from: \Zend_View_Helper_HtmlElement::_normalizeId()
Parameters
Name Type Description
$value string
Returns
Type Description
string
methodpublicdirect( ) : void

Strategy pattern: currently unutilized

Inherited from: \Zend_View_Helper_Abstract::direct()
methodpublicformErrors( string|array $errors, array $options = null ) : string

Render form errors

Parameters
Name Type Description
$errors string|array

Error(s) to render

$options array
Returns
Type Description
string
methodpublicgetClosingBracket( ) : string

Get the tag closing bracket

Inherited from: \Zend_View_Helper_HtmlElement::getClosingBracket()
Returns
Type Description
string
methodpublicgetElementEnd( ) : string

Retrieve end string for displaying errors

Returns
Type Description
string
methodpublicgetElementSeparator( ) : string

Retrieve separator string for displaying errors

Returns
Type Description
string
methodpublicgetElementStart( ) : string

Retrieve start string for displaying errors

Returns
Type Description
string
methodpublicgetTranslator( ) : \Zend_Translate

Get translator

Inherited from: \Zend_View_Helper_FormElement::getTranslator()
Returns
Type Description
\Zend_Translate
methodpublicsetElementEnd( string $string ) : \Zend_View_Helper_FormErrors

Set end string for displaying errors

Parameters
Name Type Description
$string string
Returns
Type Description
\Zend_View_Helper_FormErrors
methodpublicsetElementSeparator( string $string ) : \Zend_View_Helper_FormErrors

Set separator string for displaying errors

Parameters
Name Type Description
$string string
Returns
Type Description
\Zend_View_Helper_FormErrors
methodpublicsetElementStart( string $string ) : \Zend_View_Helper_FormErrors

Set start string for displaying errors

Parameters
Name Type Description
$string string
Returns
Type Description
\Zend_View_Helper_FormErrors
methodpublicsetTranslator( \Zend_Translate $translator = null ) : \Zend_View_Helper_FormElement

Set translator

Inherited from: \Zend_View_Helper_FormElement::setTranslator()
Parameters
Name Type Description
$translator \Zend_Translate
Returns
Type Description
\Zend_View_Helper_FormElement
methodpublicsetView( \Zend_View_Interface $view ) : \Zend_View_Helper_Abstract

Set the View object

Inherited from: \Zend_View_Helper_Abstract::setView()
Parameters
Name Type Description
$view \Zend_View_Interface
Returns
Type Description
\Zend_View_Helper_Abstract
Documentation was generated by DocBlox 0.13.3.