Batch file to upload all files in directory to FTP
<p>I'm trying to make a bat script to upload all files from a folder to an FTP server.</p>

<p>I followed the below guide and manage to get a single file uploaded but can't figure out how to upload everything in the folder.</p>

<p><a href="http://www.howtogeek.com/howto/windows/how-to-automate-ftp-uploads-from-the-windows-command-line/">How to Automate FTP Uploads from the Windows Command Line</a></p>

<p>From what I've read I think i need to somehow use the mput command?</p>

<p>At the moment my upload.bat file looks like this:</p>

<pre><code>myftp.bat .\logs\test.txt
</code></pre>

<p>inside myftp.bat is:</p>

<pre><code>@echo off
echo user MyUserName&gt; ftpcmd.dat
echo MyPassword&gt;&gt; ftpcmd.dat
echo bin&gt;&gt; ftpcmd.dat
echo put %1&gt;&gt; ftpcmd.dat
echo quit&gt;&gt; ftpcmd.dat
ftp -n -s:ftpcmd.dat MyFTPServer
del ftpcmd.dat
pause
</code></pre>