コード例 #1
0
 /**
  * 上传,html5拖拽  flash 多文件
  */
 public function fileUpload()
 {
     //show('error',false);
     $save_path = $this->path;
     if (!is_writeable($save_path)) {
         show_json($this->L['no_permission_write'], false);
     }
     if ($save_path == '') {
         show_json($this->L['upload_error_big'], false);
     }
     if (strlen($this->in['fullPath']) > 1) {
         //folder drag upload
         $full_path = _DIR_CLEAR(rawurldecode($this->in['fullPath']));
         $full_path = get_path_father($full_path);
         $full_path = iconv_system($full_path);
         if (mk_dir($save_path . $full_path)) {
             $save_path = $save_path . $full_path;
         }
     }
     //upload('file',$save_path);
     //分片上传
     $temp_dir = USER_TEMP;
     mk_dir($temp_dir);
     if (!is_writeable($temp_dir)) {
         show_json($this->L['no_permission_write'], false);
     }
     upload_chunk('file', $save_path, $temp_dir);
 }
コード例 #2
0
ファイル: web_index.php プロジェクト: jingyexu/ezcast
     break;
     //user has filled in the upload form, we need to handle the data.
 //user has filled in the upload form, we need to handle the data.
 case 'submit_media':
     submit_media();
     break;
     // Called by APC plugin to get info on current upload
 // Called by APC plugin to get info on current upload
 case 'get_upload_progress':
     get_upload_progress();
     break;
 case 'upload_init':
     upload_init();
     break;
 case 'upload_chunk':
     upload_chunk();
     break;
 case 'upload_finished':
     upload_finished();
     break;
 case 'upload_error':
     upload_error();
     break;
 case 'edit_asset':
     asset_edit();
     break;
 case 'asset_downloadable_set':
     asset_downloadable_set();
     break;
 case 'delete_asset':
     asset_delete();