View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
0003734 | mantisbt | bugtracker | public | 2004-04-11 02:17 | 2012-02-20 07:18 |
Reporter | Zakk | Assigned To | grangeway | ||
Priority | normal | Severity | major | Reproducibility | always |
Status | closed | Resolution | duplicate | ||
Product Version | 0.18.2 | ||||
Summary | 0003734: FTP upload feature is completely buggy!!! | ||||
Description | When i set $g_file_upload_method = FTP, i get so many bugs and error messages. It seems that you didn't test this feature at all. | ||||
Additional Information | I've taken a look into your source code and attached just a first bug of MANY. Please check file_api.php, proj_doc_add.php and other scripts once again. | ||||
Tags | No tags attached. | ||||
Attached Files | file_api.txt (1,016 bytes)
function file_add( $p_bug_id, $p_tmp_file, $p_file_name, $p_file_type='' ) { //... case FTP: // !!!!!!!!!!!!!!!!! WHAT'S UP GUYS?! !!!!!!!!!!!!!!!! case DISK: file_ensure_valid_upload_path( $t_file_path ); if ( !file_exists( $t_file_path . $t_new_file_name ) ) { if ( FTP == $t_method ) { // !!!!!!!!!!!!!!!! WHO WROTE THIS ?! $conn_id = file_ftp_connect(); file_ftp_put ( $conn_id, $t_new_file_name, $p_tmp_file ); file_ftp_disconnect ( $conn_id ); } umask( 0333 ); # make read only copy( $p_tmp_file, $t_file_path . $t_new_file_name ); // IF 'FTP' IS SELECTED THERE'S NO NEED TO copy() !!!!!!!!!!!!!!!!! $c_content = ''; } else { trigger_error( ERROR_FILE_DUPLICATE, ERROR ); } break; case DATABASE: $c_content = db_prepare_string( fread ( fopen( $p_tmp_file, 'rb' ), $t_file_size ) ); break; default: trigger_error( ERROR_GENERIC, ERROR ); } //... } | ||||
The FTP method uploads to both the webserver (i.e. similar to DISK) + FTP server. The idea was to use the webserver as a cache for the latest uploaded / downloaded files and the FTP server to contain all attachments. However, the implementation of this feature was not completed and hence, the webserver / FTP server always contain all attachments. There is no plans to improve on this feature in the near future, if you are using it and would like it fixed, please send your patches. |
|
Issue 0007660 seems to be the same description as this |
|