\Kendo\UI\CheckBox
A PHP wrapper for Kendo UI CheckBox.
Inherits from \Kendo\UI\Widget.
Usage
To use CheckBox in a PHP page instantiate a new instance, configure it via the available
configuration methods and output it by echo
-ing the result of the render method.
Using Kendo CheckBox
<?php
// Create a new instance of CheckBox and specify its id
$checkBox = new \Kendo\UI\CheckBox('CheckBox');
// Configure it
$checkBox->checked(true)
// Output it
echo $checkBox->render();
?>
Methods
change
Fires when the checked state of the CheckBox is changed through user interaction. For additional information check the change event documentation.
Returns
\Kendo\UI\CheckBox
Parameters
$value string|\Kendo\JavaScriptFunction
Example - using string which defines a JavaScript function
<?php
$checkBox = new \Kendo\UI\CheckBox('CheckBox');
$checkBox->change('function(e) { }');
?>
Example - using string which defines a JavaScript name
<script>
function onChange(e) {
// handle the change event.
}
</script>
<?php
$checkBox = new \Kendo\UI\CheckBox('CheckBox');
$checkBox->change('onChange');
?>
Example - using \Kendo\JavaScriptFunction
<?php
$checkBox = new \Kendo\UI\CheckBox('CheckBox');
$checkBox->change(new \Kendo\JavaScriptFunction('function(e) { }'));
?>
checked
The checked state of the CheckBox.
Returns
\Kendo\UI\CheckBox
Parameters
$value boolean
Example
<?php
$checkBox = new \Kendo\UI\CheckBox('CheckBox');
$checkBox->checked(true);
?>
enabled
If set to false, the CheckBox will be disabled and will not allow the user to change its checked state.
Returns
\Kendo\UI\CheckBox
Parameters
$value boolean
Example
<?php
$checkBox = new \Kendo\UI\CheckBox('CheckBox');
$checkBox->enabled(true);
?>
encoded
Determines whether the checkbox label content should be rendered as an HTML string or it should be encoded.
Returns
\Kendo\UI\CheckBox
Parameters
$value boolean
Example
<?php
$checkBox = new \Kendo\UI\CheckBox('CheckBox');
$checkBox->encoded(true);
?>
label
Specifies the label content for the checkbox.
Returns
\Kendo\UI\CheckBox
Parameters
$value string
Example
<?php
$checkBox = new \Kendo\UI\CheckBox('CheckBox');
$checkBox->label('value');
?>
rounded
Sets a value controlling the border radius.
Returns
\Kendo\UI\CheckBox
Parameters
$value string
Example
<?php
$checkBox = new \Kendo\UI\CheckBox('CheckBox');
$checkBox->rounded('value');
?>
size
Sets a value controlling the size of the component.
Returns
\Kendo\UI\CheckBox
Parameters
$value string
Example
<?php
$checkBox = new \Kendo\UI\CheckBox('CheckBox');
$checkBox->size('value');
?>
value
The value attribute of the widget input element.
Returns
\Kendo\UI\CheckBox
Parameters
$value string
Example
<?php
$checkBox = new \Kendo\UI\CheckBox('CheckBox');
$checkBox->value('value');
?>