Strange Upload Issue
I have a file upload issue.
I have done 777 via ftp and file manager
drwxrwxrwx 2 user user 4096 Apr 10 08:56 gallery/ drwxrwxrwx 2 user user 4096 Apr 10 10:30 sales/
I have echoed the $file_info
and the location shows as correct but the file is not uploading:开发者_运维百科
//Set File Settings
$config['upload_path'] = 'includes/uploads/gallery/';
$config['allowed_types'] = 'jpg|png';
$config['max_size'] = '100';
$config['max_width'] = '1024';
$config['max_height'] = '768';
$this->load->library('upload', $config);
$this->upload->do_upload();
$file_info = $this->upload->data();
$data = array(
'description' => $this->input->post('description', TRUE),
'path' => $file_info['file_name']
);
$this->image_model->addImage($data);
Please check write permissions? If you're using linux check also prefs of SELinux.
This issue was caused by a slow connection uploading to a server. I tried on another connection and it worked fine.
精彩评论