In a previous recipe, we have seen how to download a file using
XMLHttp. Here we will see how to upload a file to a web server using the FTP protocol.
From the File menu, navigate to New | Function Library or use the Alt + Shift + N shortcut. Name the new function library
FTP.vbs. Make sure the library is associated to the test. In order to use the code given in this recipe, you must have an FTP user account on a server. To understand this recipe, you should be familiar with FTP protocol and the command line.
In the function library, we will put the following code.
const C_FSO="Scripting.FileSystemObject" const ...