Reputation: 1607
I need to store a file on a FTP server using commands. For example FolderA/FolderB/FolderC/myfile.txt. Do I need to create each folder step by step? That would be: MKD FolderA MKD FolderB MKD FolderC STOR FolderA/FolderB/FolderC/myfile.txt
Or is there a quicker/better way to do this?
Upvotes: 3
Views: 13907
Reputation: 926
yes you can use mkd folder1/folder2/folder3
and it will create the whole tree. the same option exists on windows with mkdir
Upvotes: -1
Reputation: 46050
Some servers understand complex paths, but the standard way is to create them one by one:
MKD FolderA
CWD FolderA
MKD FolderB
CWD FolderB
MKD FolderC
CWD FolderC
STOR myfile.txt
Upvotes: 6