下面是我的控制器的代码....
public function do_upload()
{
$config['upload_path']='./upload/';
$config['allowed_types']='gif|jpg|png';
$this->load->library('upload',$config);
$this->upload->do_upload('image_file');
if($this->upload->do_upload('image_file'))
{
$filedata = $this->upload->data();
$filename = $filedata['raw_name'].$filedata['file_ext'];
return $filename;
}
}
在此调用此函数后,您要在其中进行此上传...在控制器中
if($_FILES)
{
$this->do_upload();
}
但是文件没有上传......为什么?