Permalink
Browse files

feature #4487 Documented html5 option (WouterJ)

This PR was merged into the 2.6 branch.

Discussion
----------

Documented html5 option

| Q   | A
| --- | ---
| Doc fix? | no
| New docs? | yes (symfony/symfony#8291, symfony/symfony#11994)
| Applies to | 2.6+
| Fixed tickets | #4262

Commits
-------

d08925e Yet another typo fix
238beef Typo fix
22069f4 Documented html5 option
  • Loading branch information...
weaverryan committed Nov 24, 2014
2 parents 48a5af3 + d08925e commit ed241ab0d4d8afcc78bca39f9e5ee8168bf3a6cb
@@ -22,6 +22,7 @@ day, and year) or three select boxes (see the `widget`_ option).
| Options | - `days`_ |
| | - `placeholder`_ |
| | - `format`_ |
| | - `html5`_ |
| | - `input`_ |
| | - `model_timezone`_ |
| | - `months`_ |
@@ -109,6 +110,8 @@ Alternatively, you can specify a string to be displayed for the "blank" value::
.. include:: /reference/forms/types/options/date_format.rst.inc
.. include:: /reference/forms/types/options/html5.rst.inc
.. _form-reference-date-input:
.. include:: /reference/forms/types/options/date_input.rst.inc
@@ -21,6 +21,7 @@ data can be a ``DateTime`` object, a string, a timestamp or an array.
| | - `placeholder`_ |
| | - `format`_ |
| | - `hours`_ |
| | - `html5`_ |
| | - `input`_ |
| | - `minutes`_ |
| | - `model_timezone`_ |
@@ -82,6 +83,8 @@ field to be rendered as an ``input`` field with ``type="datetime"``.
.. include:: /reference/forms/types/options/hours.rst.inc
.. include:: /reference/forms/types/options/html5.rst.inc
input
~~~~~
@@ -0,0 +1,13 @@
html5
~~~~~
.. versionadded:: 2.6
The ``html5`` option was introduced in Symfony 2.6.
**type**: ``boolean`` **default**: ``true``
If this is set to ``true`` (the default), it'll use the HTML5 type (date, time
or datetime) to render the field. When set to ``false``, it'll use the text type.
This is useful when you want to use a custom JavaScript datapicker, which
often requires a text type instead of an HTML5 type.
@@ -17,6 +17,7 @@ as a ``DateTime`` object, a string, a timestamp or an array.
+----------------------+-----------------------------------------------------------------------------+
| Options | - `placeholder`_ |
| | - `hours`_ |
| | - `html5`_ |
| | - `input`_ |
| | - `minutes`_ |
| | - `model_timezone`_ |
@@ -81,6 +82,8 @@ Field Options
.. include:: /reference/forms/types/options/hours.rst.inc
.. include:: /reference/forms/types/options/html5.rst.inc
input
~~~~~

0 comments on commit ed241ab

Please sign in to comment.