system/classes/Validate.php
public function setCheckbox($name, $value, $default = false)
    {
        if (isset($this->data[$name])) {
            $return = '';
            foreach ($this->data[$name] as $checkBox) {
                if ($checkBox == $value) {
                    $return = 'checked';
                }
            }
            return $return;
        }
        else {
            if ($default) {
                return 'checked';
            }
            else {
                return '';
            }
        }
    }
public function setCheckbox($name, $value, $default = false)
    {
        if (isset($this->data[$name])) {
            $return = '';
            foreach ($this->data[$name] as $checkBox) {
                if ($checkBox == $value) {
                    $return = 'checked';
                }
            }
            return $return;
        }
        else {
            if ($default) {
                return 'checked';
            }
            else {
                return '';
            }
        }
    }
For resetting a form Checkbox's data after a failed validation.
$name = checkbox's name
$value = checkbox's value
$default = whether this checkbox should be checked by default.