Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public function ajaxFileUpload(){
- if($this->input->is_ajax_request()){
- if(hasPermission("importFileData")){
- $options = array(
- 'script_url'=> current_url(),
- 'upload_dir'=> BASE_PATH.PATH_UPLOADS_DATA_USERS.$this->data["loggedUser"]->userID."/",
- 'upload_url'=> base_url(PATH_UPLOADS_DATA_USERS.$this->data["loggedUser"]->userID)."/",
- 'accept_file_types'=> '/\.('.implode("|", Data_import_model::$ALLOWED_TYPES).')$/i',
- 'max_file_size'=> Data_import_model::$MAX_FILE_SIZE,
- 'delete_type' => "POST"
- );
- $this->load->library('customUploadHandler', $options);
- }else{
- die(dictionary("message_noPermissions"));
- }
- }else{
- die(dictionary("message_noDirectAccess"));
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement