<commit_before><?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 <EMAIL> so we can send you a copy immediately.
 *
 * @category   Zend
 * @package    Zend_Form
 * @subpackage View
 * @copyright  Copyright (c) 2005-2012 Zend Technologies USA Inc. (http://www.zend.com)
 * @license    http://framework.zend.com/license/new-bsd     New BSD License
 */

namespace Zend\Form\View\Helper;

use Zend\Form\ElementInterface;
use Zend\Loader\Pluggable;
use Zend\View\Helper\AbstractHelper as BaseAbstractHelper;
use Zend\View\Helper\Doctype;
use Zend\View\Helper\Escape;

/**
 * Base functionality for all form view helpers
 *
 * @category   Zend
 * @package    Zend_Form
 * @subpackage View
 * @copyright  Copyright (c) 2005-2012 Zend Technologies USA Inc. (http://www.zend.com)
 * @license    http://framework.zend.com/license/new-bsd     New BSD License
 */
abstract class AbstractHelper extends BaseAbstractHelper
{
    /**
     * Standard boolean attributes, with expected values for enabling/disabling
     * 
     * @var array
     */
    protected $booleanAttributes = array(
        'autocomplete' => array('on' => 'on',        'off' => 'off'),
        'autofocus'    => array('on' => 'autofocus', 'off' => ''),
        'checked'      => array('on' => 'checked',   'off' => ''),
        'disabled'     => array('on' => 'disabled',  'off' => ''),
        'multiple'     => array('on' => 'multiple',  'off' => ''),
        'readonly'     => array('on' => 'readonly',  'off' => ''),
        'required'     => array('on' => 'required',  'off' => ''),
        'selected'     => array('on' => 'selected',  'off' => ''),
    );

    /**
     * @var Doctype
     */
    protected $doctypeHelper;

    /**
     * @var Escape
     */
    protected $escapeHelper;

    /**
     * Valid attributes for form markup
     * 
     * @var array
     */
    protected $validAttributes = array(
        'accept'             => true,
        'accesskey'          => true,
        'alt'                => true,
        'autocomplete'       => true,
        'autofocus'          => true,
        'checked'            => true,
        'class'              => true,
        'cols'               => true,
        'contenteditable'    => true,
        'contextmenu'        => true,
        'dir'                => true,
        'dirname'            => true,
        'disabled'           => true,
        'draggable'          => true,
        'dropzone'           => true,
        'form'               => true,
        'formaction'         => true,
        'formenctype'        => true,
        'formmethod'         => true,
        'formnovalidate'     => true,
        'formtarget'         => true,
        'height'             => true,
        'hidden'             => true,
        'id'                 => true,
        'label'              => true,
        'lang'               => true,
        'list'               => true,
        'max'                => true,
        'maxlength'          => true,
        'min'                => true,
        'multiple'           => true,
        'name'               => true,
        'onabort'            => true,
        'onblur'             => true,
        'oncanplay'          => true,
        'oncanplaythrough'   => true,
        'onchange'           => true,
        'onclick'            => true,
        'oncontextmenu'      => true,
        'ondblclick'         => true,
        'ondrag'             => true,
        'ondragend'          => true,
        'ondragenter'        => true,
        'ondragleave'        => true,
        'ondragover'         => true,
        'ondragstart'        => true,
        'ondrop'             => true,
        'ondurationchange'   => true,
        'onemptied'          => true,
        'onended'            => true,
        'onerror'            => true,
        'onfocus'            => true,
        'oninput'            => true,
        'oninvalid'          => true,
        'onkeydown'          => true,
        'onkeypress'         => true,
        'onkeyup'            => true,
        'onload'             => true,
        'onloadeddata'       => true,
        'onloadedmetadata'   => true,
        'onloadstart'        => true,
        'onmousedown'        => true,
        'onmousemove'        => true,
        'onmouseout'         => true,
        'onmouseover'        => true,
        'onmouseup'          => true,
        'onmousewheel'       => true,
        'onpause'            => true,
        'onplay'             => true,
        'onplaying'          => true,
        'onprogress'         => true,
        'onratechange'       => true,
        'onreadystatechange' => true,
        'onreset'            => true,
        'onscroll'           => true,
        'onseeked'           => true,
        'onseeking'          => true,
        'onselect'           => true,
        'onshow'             => true,
        'onstalled'          => true,
        'onsubmit'           => true,
        'onsuspend'          => true,
        'ontimeupdate'       => true,
        'onvolumechange'     => true,
        'onwaiting'          => true,
        'pattern'            => true,
        'placeholder'        => true,
        'readonly'           => true,
        'required'           => true,
        'rows'               => true,
        'selected'           => true,
        'size'               => true,
        'spellcheck'         => true,
        'src'                => true,
        'step'               => true,
        'style'              => true,
        'tabindex'           => true,<commit_msg>[zen-48] Added attributes for form, label<commit_after><?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 <EMAIL> so we can send you a copy immediately.
 *
 * @category   Zend
 * @package    Zend_Form
 * @subpackage View
 * @copyright  Copyright (c) 2005-2012 Zend Technologies USA Inc. (http://www.zend.com)
 * @license    http://framework.zend.com/license/new-bsd     New BSD License
 */

namespace Zend\Form\View\Helper;

use Zend\Form\ElementInterface;
use Zend\Loader\Pluggable;
use Zend\View\Helper\AbstractHelper as BaseAbstractHelper;
use Zend\View\Helper\Doctype;
use Zend\View\Helper\Escape;

/**
 * Base functionality for all form view helpers
 *
 * @category   Zend
 * @package    Zend_Form
 * @subpackage View
 * @copyright  Copyright (c) 2005-2012 Zend Technologies USA Inc. (http://www.zend.com)
 * @license    http://framework.zend.com/license/new-bsd     New BSD License
 */
abstract class AbstractHelper extends BaseAbstractHelper
{
    /**
     * Standard boolean attributes, with expected values for enabling/disabling
     * 
     * @var array
     */
    protected $booleanAttributes = array(
        'autocomplete' => array('on' => 'on',        'off' => 'off'),
        'autofocus'    => array('on' => 'autofocus', 'off' => ''),
        'checked'      => array('on' => 'checked',   'off' => ''),
        'disabled'     => array('on' => 'disabled',  'off' => ''),
        'multiple'     => array('on' => 'multiple',  'off' => ''),
        'readonly'     => array('on' => 'readonly',  'off' => ''),
        'required'     => array('on' => 'required',  'off' => ''),
        'selected'     => array('on' => 'selected',  'off' => ''),
    );

    /**
     * @var Doctype
     */
    protected $doctypeHelper;

    /**
     * @var Escape
     */
    protected $escapeHelper;

    /**
     * Valid attributes for form markup
     * 
     * @var array
     */
    protected $validAttributes = array(
        'accept'             => true,
        'accept-charset'     => true,
        'accesskey'          => true,
        'action'             => true,
        'alt'                => true,
        'autocomplete'       => true,
        'autofocus'          => true,
        'checked'            => true,
        'class'              => true,
        'cols'               => true,
        'contenteditable'    => true,
        'contextmenu'        => true,
        'dir'                => true,
        'dirname'            => true,
        'disabled'           => true,
        'draggable'          => true,
        'dropzone'           => true,
        'enctype'            => true,
        'for'                => true,
        'form'               => true,
        'formaction'         => true,
        'formenctype'        => true,
        'formmethod'         => true,
        'formnovalidate'     => true,
        'formtarget'         => true,
        'height'             => true,
        'hidden'             => true,
        'id'                 => true,
        'label'              => true,
        'lang'               => true,
        'list'               => true,
        'max'                => true,
        'maxlength'          => true,
        'method'             => true,
        'min'                => true,
        'multiple'           => true,
        'name'               => true,
        'novalidate'         => true,
        'onabort'            => true,
        'onblur'             => true,
        'oncanplay'          => true,
        'oncanplaythrough'   => true,
        'onchange'           => true,
        'onclick'            => true,
        'oncontextmenu'      => true,
        'ondblclick'         => true,
        'ondrag'             => true,
        'ondragend'          => true,
        'ondragenter'        => true,
        'ondragleave'        => true,
        'ondragover'         => true,
        'ondragstart'        => true,
        'ondrop'             => true,
        'ondurationchange'   => true,
        'onemptied'          => true,
        'onended'            => true,
        'onerror'            => true,
        'onfocus'            => true,
        'oninput'            => true,
        'oninvalid'          => true,
        'onkeydown'          => true,
        'onkeypress'         => true,
        'onkeyup'            => true,
        'onload'             => true,
        'onloadeddata'       => true,
        'onloadedmetadata'   => true,
        'onloadstart'        => true,
        'onmousedown'        => true,
        'onmousemove'        => true,
        'onmouseout'         => true,
        'onmouseover'        => true,
        'onmouseup'          => true,
        'onmousewheel'       => true,
        'onpause'            => true,
        'onplay'             => true,
        'onplaying'          => true,
        'onprogress'         => true,
        'onratechange'       => true,
        'onreadystatechange' => true,
        'onreset'            => true,
        'onscroll'           => true,
        'onseeked'           => true,
        'onseeking'          => true,
        'onselect'           => true,
        'onshow'             => true,
        'onstalled'          => true,
        'onsubmit'           => true,
        'onsuspend'          => true,
        'ontimeupdate'       => true,
        'onvolumechange'     => true,
        'onwaiting'          => true,
        'pattern'            => true,
        'placeholder'        => true,
        'readonly'           => true,
        'required'           => true,
        'rows'               => true,
        'selected'           => true,
        'size'               => true,
        'spellcheck'         => true,
        'src'                => true,
        'step'               => true,
        'style'              => true,
        'tabindex'           => true,
        'target'             => true,
{'fraction_non_alphanumeric': 0.13831714144574345, 'fraction_numerical': 0.002799275481640046, 'mean_word_length': 1.262432482771466, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 254, 'https://': 0, 'lorem ipsum': 0, 'www.': 4, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7550955', 'n_tokens_mistral': 3495, 'n_tokens_neox': 3406, 'n_words': 802}