hello...i have up and running the 3.3b version and its working good minus the fact that if i upload a file and then try to download it...it opens corrupt. this is on pdf, word and excel....notepad txt files seems to work fine.
unfortantely i can not seem to figure why this is happening and can not use this product unless this is fixed
Logged In: YES
user_id=1940799
Originator: NO
I'm having the same problem with phpwebftp. I noticed that when downloading the file is corrupted because the file size is a few bytes smaller than the actual file. So I guess it's not downloading everything. Maybe a problem with compression?
Logged In: NO
I have the same problem both with 3.3 and 4.0
Logged In: NO
Same problem for me...Files are still corrupted during upload.
Tested with all versions including 4.0.
This is a big problem. My ftp serveur is on OVH.
Logged In: NO
i dropped this and got upload pro working and doing more then this web app can do.
Logged In: NO
same problem for me.all files corupted during upload.
Otherwise, it's seems to be a good script.
Logged In: NO
Same problem here !
the usage of the php function for ftp command is wrong. They are using "0" and "1" for ascii or binary tranfer. In fact php needs a different syntax.. If anyone is interested, I can put a patchfile on my webserver...
I had the same problem.
Solution: As it was written before "the usage of the php function for ftp command is wrong", thus, in the file inlcude/ftp.class.php I replaced number 0 and 1 with this "FTP_BINARY" on lines 25 and 67.
Line 25 of ftp.class.php becomes:
var $mode = FTP_BINARY;
and line 67 becomes:
function setMode($mode=FTP_BINARY) {
In this way works for me.
We have exactly the same issue. Text files are fine but other filetypes corrupt when they are uploaded (doc/xls). Tried yellowjug's solution with FTP_BINARY but this doesn't correct it for us.
It maybe something to do with the server config. This is an interesting thread at Metafilter:
http://ask.metafilter.com/85404/PHP-Uploads-Result-in-Corrupt-Files
However net2ftp seems to work so it could be related to the coding/structure of this app. Any help people have would be appreciated, this is quite frustrating.
Actually looking at some of the bug submits here (2007 and not assigned to anyone yet) this looks like a dead project.
I have listed all the needed files and lines of code for changing the reference to mode from (0 | 1) -- > (FTP_ASCII | FTP_BINARY):
index.php:
line 417:
change - $newMode=($ftp->mode==1)?0:1;
new code - $newMode=($ftp->mode==FTP_BINARY)?FTP_ASCII:FTP_BINARY;
line 651:
change - $newMode=($ftp->mode==1)?0:1;
new code - $newMode=($ftp->mode==FTP_BINARY)?FTP_ASCII:FTP_BINARY;
line 950:
change - <?=$ftp->mode==FTP_BINARY?$lblBinaryMode:$lblASCIIMode;?>
new code - <?=$ftp->mode==0?$lblBinaryMode:$lblASCIIMode;?>
include/ftp.class.php
line 25:
change - var $mode = 1;
new code - var $mode = FTP_BINARY;
line 67:
change - function setMode($mode=0) {
new code - function setMode($mode=FTP_ASCII) {
I confirm rfidler's solution fixes file corruption problem!
(One small note to his solution: in paragraph called "line 950": code for "change" and "new code" should be actually swapped)