1<?php
2/**
3 * Zend Framework (http://framework.zend.com/)
4 *
5 * @link      http://github.com/zendframework/zf2 for the canonical source repository
6 * @copyright Copyright (c) 2005-2015 Zend Technologies USA Inc. (http://www.zend.com)
7 * @license   http://framework.zend.com/license/new-bsd New BSD License
8 */
9
10namespace Zend\Form\View\Helper;
11
12use Zend\Form\ElementInterface;
13use Zend\Form\Exception;
14
15class FormSubmit extends FormInput
16{
17    /**
18     * Attributes valid for the input tag type="submit"
19     *
20     * @var array
21     */
22    protected $validTagAttributes = array(
23        'name'           => true,
24        'autofocus'      => true,
25        'disabled'       => true,
26        'form'           => true,
27        'formaction'     => true,
28        'formenctype'    => true,
29        'formmethod'     => true,
30        'formnovalidate' => true,
31        'formtarget'     => true,
32        'type'           => true,
33        'value'          => true,
34    );
35
36    /**
37     * Translatable attributes
38     *
39     * @var array
40     */
41    protected $translatableAttributes = array(
42        'value' => true
43    );
44
45    /**
46     * Determine input type to use
47     *
48     * @param  ElementInterface $element
49     * @throws Exception\DomainException
50     * @return string
51     */
52    protected function getType(ElementInterface $element)
53    {
54        return 'submit';
55    }
56}
57