LaravelBook\Laravel4Powerpack\Form::checkable PHP Method

checkable() protected method

Create a checkable input element.
protected checkable ( string $type, string $name, string $value, boolean $checked, array $attributes ) : string
$type string
$name string
$value string
$checked boolean
$attributes array
return string
    protected function checkable($type, $name, $value, $checked, $attributes)
    {
        if ($checked) {
            $attributes['checked'] = 'checked';
        }
        $attributes['id'] = $this->id($name, $attributes);
        return $this->input($type, $name, $value, $attributes);
    }