cURL / Mailing Lists / curl-and-php / Single Mail

curl-and-php

Re: Moving files on an FTP server via libcurl

From: Vipin hegde <vipinhegde_at_gmail.com>
Date: Thu, 28 Jun 2007 15:36:58 -0700

I split the command in two, as Daniel pointed out. Still no luck. I have
the verbose flag turned on and I see no error message or warning which
might give a clue as to why the files are not being moved over.
========================================================================================
  $cobj = curl_init();
  curl_setopt($cobj, CURLOPT_URL, $ftp_url);
  curl_setopt($cobj, CURLOPT_RETURNTRANSFER,1);
  curl_setopt($cobj, CURLOPT_VERBOSE, 1);
  curl_setopt($cobj, CURLOPT_USERPWD, $username . ":" . $password);
  curl_setopt($cobj, CURLOPT_FTP_USE_EPSV, 0);
  curl_setopt($cobj, CURLOPT_FTP_USE_EPRT, 0);
  curl_setopt($cobj, CURLOPT_FTP_SSL, CURLFTPSSL_ALL);
  curl_setopt($cobj, CURLOPT_SSL_VERIFYPEER, 0);
  curl_setopt($cobj, CURLOPT_SSL_VERIFYHOST, 0);
  curl_setopt($cobj, CUROPT_POSTQUOTE, array("RNFR $filename"));
  curl_setopt($cobj, CUROPT_POSTQUOTE, array("RNTO
old_datafiles/$filename"));

========================================================================================
Regards,
Vipin

_______________________________________________
http://cool.haxx.se/cgi-bin/mailman/listinfo/curl-and-php
Received on 2007-06-29