在create之后post过来的值写不到数据库

浏览:766 发布日期:2015/02/10 分类:求助交流 关键字: create 传值 add
$data['Typename'] = I('post.typename','','htmlspecialchars');
            $data['Status'] = I('post.status','');
            //自动完成验证与新增
            $type=D('Shoptype');
            if ($type->create($data)) {
                $type->add();
                parent::operating(__ACTION__,0,'新增店铺分类:'.$data['Typename']);
                R('Public/errjson',array('ok'));
            }else {
                parent::operating(__ACTION__,1,'新增失败:'.$data['Typename']);
                R('Public/errjson',array($type->getError()));
            }
为什么在create之后。。add的结果中$data的值就丢失了。求各位大侠帮我看看。谢谢
最佳答案
评论() 相关
后面还有条评论,点击查看>>