thinkphp数据库添加表单提交的数据

$data['catename'] = I('catename');     获取表单的数据
$cate=D('cate');                               实例化cate表
$cate->create($data);                      根据提交数组创建数据对象
$cate->add();                                  数据对象入库

原文地址:https://www.cnblogs.com/txxt/p/5653222.html