ฟอร์มข้อมูล
Code
<?php
//ini_set('display_errors', 1);
//ini_set('display_startup_errors', 1);
//error_reporting(E_ALL);
require_once('public/generate-form-dev.php');
$form=new Form();

//$field=$db->getFieldFromTable('sample',['number_int']);
$field=$db->getFieldFromSql('select number_int from sample;');
$form->addField($field);
echo '<pre>';print_r($field);
$form->addObject(['type'=>'submit','value'=>'เพิ่มข้อมูล'],['type'=>'back']);
echo $form->create(); 
ผลลัพธ์
Array
(
    [number_int] => Array
        (
            [name] => number_int
            [orgname] => number_int
            [table] => sample
            [orgtable] => sample
            [def] => 
            [db] => framework
            [catalog] => def
            [max_length] => 0
            [length] => 10
            [charsetnr] => 63
            [flags] => 36897
            [type] => int unsigned
            [decimals] => 0
            [label] => ตัวเลข (int)
            [type_search] => int unsigned
            [null] => NO
            [orgname2] => sample.number_int
            [order] => 0
            [min] => 0
            [max] => 4294967295
            [list] => 
        )

)