eZ Systems Website
  Editor documentation

  Developer documentation

  Back to the top

The documentation is moving!

We're moving our developer docs to Github and a new site.
The migration is still in progress, so please contact us in #documentation-contrib on eZ Community Slack if you have any questions or feedback.

This space will not be updated from now on except for critical fixes.

Skip to end of metadata
Go to start of metadata

This field type represents a Checkbox status, checked or unchecked.

NameInternal nameExpected input type


The Checkbox Field Type stores the current status for a checkbox input, checked of unchecked, by storing a boolean value.

PHP API Field Type 

Value object


The Value class of this Field Type contains the following properties:

PropertyTypeDefault valueDescription
$boolbooleanfalseThis property will be used for the checkbox status, which will be represented by a boolean value.
Value object content examples

The Checkbox\Value constructor accepts a boolean value:

Constructor example
String representation

As this Field Type is not a string but a bool, it will return "1" (true) or "0" (false) in cases where it is cast to string.