Skip to content
This repository has been archived by the owner on May 24, 2018. It is now read-only.

Latest commit

 

History

History
27 lines (16 loc) · 731 Bytes

zend.form.view.helper.form-month.rst

File metadata and controls

27 lines (16 loc) · 731 Bytes

FormMonth

The FormMonth view helper can be used to render a <input type="month"> HTML5 form input. It is meant to work with the Zend\\Form\\Element\\Month <zend.form.element.month> element, which provides a default input specification for validating HTML5 date values.

FormMonth extends from Zend\\Form\\View\\Helper\\FormDateTime <zend.form.view.helper.form-date-time>.

Basic usage:

use Zend\Form\Element;

$element = new Element\Month('my-month');

// Within your view...

echo $this->formMonth($element);
// <input type="month" name="my-month" value="">