title: FTP login not authorizing through PHP methods
body: <p>I'm having trouble connecting to my ftp server in PHP.  I'm able to log in using the telnet command from the cmd prompt, so the server/user/password is correct, but when I attempt to connect using PHP I get an error: </p>
  
  <blockquote>
    <p>Warning: ftp_login() [function.ftp-login]: Login incorrect. in
    /hermes/bosweb/web232/b2323/ipg....</p>
  </blockquote>
  
  <p>When I comment out my server/user/pass and replace with a public anonymous ftp server the code works (as shown below).  I've been searching for an answer for the past week but still have no clue what I'm missing or where else to look.  Also, I'm a php/server newbie, so it might be something really simple.  Any help is greatly appreciated!</p>
  
  <pre><code>&lt;?php
      /*
      // (does not work)
      $ftp_server = "ftp.*****.com";
      $ftp_user = "******";
      $ftp_password = "*****";
      */
  
      $ftp_server = "ftp.gnu.org";
      $ftp_user = "anonymous";
      $ftp_password = "none";
  
  
      /* connect */
      $ftp_connection = @ftp_connect($ftp_server);
      if (!$ftp_connection) die('could not connect.');
  
      /* login */
      $ftp_login = @ftp_login($ftp_connection, $ftp_user, $ftp_password);
      if (!$ftp_login) die('could not login.');
  
      /* enter passive mode */
      $ftp_passive = @ftp_pasv($ftp_connection, true);
      if (!$ftp_passive) die('could not enable passive mode.');
  
      /* get listing */
      $ftp_listing = ftp_nlist($ftp_connection, "."); 
      foreach ($ftp_listing as $file){
          echo "&lt;div&gt;".$file."&lt;/div&gt;";
      }
  
      ftp_close($ftp_connection);
  ?&gt;
  </code></pre>