title: Why would uploading a zip file via ftp_fput return true but not upload the file?
body: <p>The following command returns true and uploads the text XML file to the FTP server:</p>
  
  <pre><code>if (ftp_put($this-&gt;ftpConnectionId, $this-&gt;remoteXmlFileName, $this-&gt;localXmlFileName, FTP_ASCII)) {
  </code></pre>
  
  <p>However, when I try to upload a .zip file intead of a text XML file, it still returns true but does not upload the file:</p>
  
  <pre><code>if (ftp_put($this-&gt;ftpConnectionId, $this-&gt;remoteXmlFileName, $this-&gt;localXmlFileName, FTP_BINARY)) {
  </code></pre>
  
  <p>I found that if I simply rename the zip file to ".xml", it WILL upload the file but the .zip file is corrupted.</p>
  
  <p>But if I rename the zip file to ".zip.xml" it again returns true but does not upload the file.</p>
  
  <p><strong>What could be the reasons for this odd behavior?</strong></p>
  
  <h2>Additional Info:</h2>
  
  <p>A zip file can be uploaded via FileZilla no problem with the same account.</p>
  
  <p>I also am specifing:</p>
  
  <pre><code>ftp_pasv($this-&gt;ftpConnectionId, true);
  </code></pre>