HEX
Server: Microsoft-IIS/8.5
System: Windows NT YDAWBH120 6.3 build 9600 (Windows Server 2012 R2 Standard Edition) AMD64
User: tentjecom_web (0)
PHP: 7.4.14
Disabled: NONE
Upload Files
File: D:/HostingSpaces/SBogers18/decoockpit.nl/wwwroot/kms/lib/form/types/field_type_checkbox.class.php
<?php
/**
 * field_type_active.class.php
 * Created by Komma Mediadesign.
 * Author: mike
 * Date: 4/3/13
 */

class Field_Type_Checkbox extends Form_Field
{
    public function construct(){}

    public function createInput()
    {
        $key = array($this->_info['form_name'] . '_data',$this->_info['name']);
        $val = 0;
        $val = Session::get($key);

        $output = '';
        $output .= '<input type="checkbox" name="' . $this->_info['name'] .'" value="1" ';
        if($val == 1) $output .= 'checked';
        $output .= '/>' . $this->_info['label'] ;

        return $output;
    }

}