TP里面的Upload类的疑问
public function add_article(){<br /> if($this->create()){<br /> p($_POST);<br /> p($_FILES);<br /> if(!empty($_FILES['thumb']['name'])){<br /> $upload = new \Think\Upload();<br /> $upload->savePath = './upload/article/';<br /> $upload->exts = array('jpg', 'gif', 'png', 'jpeg');<br /> $upload->maxSize = 3145728;<br /> $info = $upload->upload();<br /> print_r($info);die;<br /> $this->data['thumb']=$file[0]['path'];<br /> }<br /> return $this->add();<br /><br /> }<br /> }