I'm trying to use FTP.EXE to send and get files with spaces in them. For instance, it works fine with a file such as "myfile.txt" but fails with "my file.txt". Does anyone know how to get this working? I tried using the 'literal' command with 'RETR my file.txt' but that seems to hang the software. I am quite aware that I could be using another FTP client, but I need FTP.EXE to work because I've tied it into my program. If you don't know how to solve the problem with FTP.EXE, suggesting another command-line program would be useful. Thanks in advance.
GHz
http://www.planetquake.com/vortex
ghz@planetquake.com
Page 1 of 1
Need Help with FTP.EXE
#2
Posted 16 April 2003 - 06:00 PM
Quote:
I'm trying to use FTP.EXE to send and get files with spaces in them. For instance, it works fine with a file such as "myfile.txt" but fails with "my file.txt". Does anyone know how to get this working? I tried using the 'literal' command with 'RETR my file.txt' but that seems to hang the software. I am quite aware that I could be using another FTP client, but I need FTP.EXE to work because I've tied it into my program. If you don't know how to solve the problem with FTP.EXE, suggesting another command-line program would be useful. Thanks in advance.
GHz
http://www.planetquake.com/vortex
ghz@planetquake.com
GHz
http://www.planetquake.com/vortex
ghz@planetquake.com
Try putting the file name in quotes (try "my file.txt" first and then 'my file.txt')
#3
Posted 16 April 2003 - 06:09 PM
That's the first thing I tried. Doesn't work 
GHz
http://www.planetquake.com/vortex
ghz@planetquake.com
GHz
http://www.planetquake.com/vortex
ghz@planetquake.com
#6
Posted 16 April 2003 - 10:15 PM
Homeboy has got it right. Anywhere there would be a spcae, put %20 instead.
#7
Posted 17 April 2003 - 02:30 AM
Yes, my application creates the script files dynamically based upon user input. If you're really curious, I'm using the FTP as a subsystem to transfer character data to and from my Quake 2 server to a master FTP database. This allows players of my Q2 RPG mod to play their character from any server, provided they have my special software (and FTP.EXE of course!).
Thanks for the help guys, I'll try out your suggestions tonight.
GHz
http://www.planetquake.com/vortex
ghz@planetquake.com
Thanks for the help guys, I'll try out your suggestions tonight.
GHz
http://www.planetquake.com/vortex
ghz@planetquake.com
#8
Posted 17 April 2003 - 03:32 PM
Quote:
Yes, my application creates the script files dynamically based upon user input. If you're really curious, I'm using the FTP as a subsystem to transfer character data to and from my Quake 2 server to a master FTP database. This allows players of my Q2 RPG mod to play their character from any server, provided they have my special software (and FTP.EXE of course!).
Thanks for the help guys, I'll try out your suggestions tonight.
GHz
http://www.planetquake.com/vortex
ghz@planetquake.com
Thanks for the help guys, I'll try out your suggestions tonight.
GHz
http://www.planetquake.com/vortex
ghz@planetquake.com
Why don't you just write the ftp into the software. I don't know what kind of language you are using but I doubt it is that hard to do. You could probably find a library out there with all the socket based programming done for you. It would take away the need for FTP.exe. Just something to think about, especially if my above suggestion doesn't work.
#9
Posted 18 April 2003 - 01:04 AM
Quote:
Quote:
Quote:
Yes, my application creates the script files dynamically based upon user input. If you're really curious, I'm using the FTP as a subsystem to transfer character data to and from my Quake 2 server to a master FTP database. This allows players of my Q2 RPG mod to play their character from any server, provided they have my special software (and FTP.EXE of course!).
Thanks for the help guys, I'll try out your suggestions tonight.
GHz
http://www.planetquake.com/vortex
ghz@planetquake.com
Thanks for the help guys, I'll try out your suggestions tonight.
GHz
http://www.planetquake.com/vortex
ghz@planetquake.com
Why don't you just write the ftp into the software. I don't know what kind of language you are using but I doubt it is that hard to do. You could probably find a library out there with all the socket based programming done for you. It would take away the need for FTP.exe. Just something to think about, especially if my above suggestion doesn't work.
Warning him ahead of time: I wrote an FTP client...
I found out that downloading stuff is simpler than uploading them, no question... I got by it & around some hassles I had with it (most all of them I think with MOST ftp servers, but not all), but was headache & VERY frustrating!
In fact, the MOST frustrating problem I have ever run into programming actually!
(This problem boggled my mind for a good 1/2 year in fact, but I wrote it from scratch & did ALOT of porting of the C/C++ code for it to Delphi... I solved it with time & hassle, but it was a PAIN!)
* That's why I was wondering if he was scripting FTP.exe itself...
APK
P.S.=> BUT, VG does have a point: I think that WSFTP's sourcecode is up online & freely available too... no joke! Trick is, he may not be used to the C/C++ code I believe it is written in... apk
I have written a simple http client/server in c. There is pleanty of documentation and source code out there if you wanted to go that way as well. I doubt ftp is much different.
Share this topic:
Page 1 of 1

Help










