File tree Expand file tree Collapse file tree 1 file changed +5
-5
lines changed
reference/forms/types/options Expand file tree Collapse file tree 1 file changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -16,8 +16,8 @@ more control::
1616 'no' => false,
1717 'maybe' => null,
1818 ],
19- 'choice_label' => function ($choiceValue , $key, $value ) {
20- if ($value == $choiceValue ) {
19+ 'choice_label' => function ($value , $key, $choiceValue ) {
20+ if (true === $value ) {
2121 return 'Definitely!';
2222 }
2323
@@ -28,9 +28,9 @@ more control::
2828 },
2929 ]);
3030
31- This method is called for *each* choice, passing you the choice ``$value`` and the
32- ``$key`` from the choices array (``$index `` is related to `choice_value`_). This
33- will give you:
31+ This method is called for *each* choice, passing you the ``$value`` and
32+ ``$key`` from the choices array (additional ``$choiceValue `` is related to `choice_value`_).
33+ This will give you:
3434
3535.. image:: /_images/reference/form/choice-example2.png
3636 :align: center
You can’t perform that action at this time.
0 commit comments