Jump to content

Please some one help on ftp_login() error


vapanchamukhi1

Recommended Posts

I have written a piece of code for ftp connection. I am able to connect to ftp server. but when i try to login to the ftp server using user name and password it is giving me following error.

 

Warning: ftp_login() [function.ftp-login]: End in .\FtpServerFileProcess.php on line 35

the code is as below,

       public function loginToFTP() {
          // login with username and password
          $this->login_result = ftp_login($this->conn_id, $this->ftp_user_name, $this->ftp_user_pass);
          ftp_pasv($this->conn_id, true);
          return $this->login_result;
          // check login
       /*   if ((!$this->login_result)) {
                  echo "FTP connection has failed!";
                  echo "Attempted to Login to $this->ftp_server for user $this->ftp_user_name";
                  exit;
                    } else {
                  echo "Loggedin into $this->ftp_server, for user $this->ftp_user_name";
          }
       */   
       }



where conn_id is the connection handler that i got after connecting to the ftp server.
ftp_user_name is User name using which i am trying to login to the ftp server
ftp_user_pass is the password using which i am trying to login to the ftp server.

Please some one help to understand the meaning of the error and also the way of getting rid of that error.

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.