Closed lstables closed 11 years ago
Yes, you'd still need to load the upload library and configure it. The only difference between using this extension and the default codeigniter library is that you call do_multi_upload() instead of do_upload() to perform your upload. For example:
//Load upload library.
$this->load->library("upload");
//Initialize upload.
$this->upload->initialize(array(
"allowed_types" => "gifjpg|png",
"upload_path" => "/path/to/upload/directory/"
));
//Do multi-upload.
if($this->upload->do_multi_upload("file")){
//Code executed upon successful upload.
}
or right so i can just perform the new upload instead then, what if there's only one upload would it revert backt o CI upload?
If only one file upload is being performed, the multi-upload will fallback to the do_upload() method provided by codeigniter. You can see the check for multiple files and the fallback to the do_upload() method on lines 264-268 of MY_Upload.php.
YOu Library doesnt work I done what you said but dont you have to load the lib?