![]() |
FTP Class: file_exists() does not work - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20) +--- Forum: Archived General Discussion (https://forum.codeigniter.com/forumdisplay.php?fid=21) +--- Thread: FTP Class: file_exists() does not work (/showthread.php?tid=56122) |
FTP Class: file_exists() does not work - El Forum - 11-27-2012 [eluser]WoolyG[/eluser] Hi all, Take a look: Code: public function cron_download_transaction_data() I am able to CHMOD the files, which proves that they exist (I see the permissions changing), but always get "File X does not exist". Do standard PHP file commands not work with the FTP class? All input appreciated. Thanks, Wooly FTP Class: file_exists() does not work - El Forum - 11-27-2012 [eluser]monoclonal[/eluser] maybe a safe mode issue? FTP Class: file_exists() does not work - El Forum - 11-27-2012 [eluser]Aken[/eluser] PHP file commands are relevant to the local server that PHP is installed on. The FTP class utilizes the ftp_* set of functions. You can use $this->ftp->list_files() to get a list of current files and see if it is uploaded. Or you can extend the FTP library with additional functionality. If you do the latter, consider contributing those additions to CodeIgniter's Github repo to expand CI. FTP Class: file_exists() does not work - El Forum - 11-28-2012 [eluser]InsiteFX[/eluser] Maybe take a look at this: Code: '/var/www/assets/import/folder1/'.$file, Now look at your $files_array, you are adding on an extra forward slash... Remove the forward slash off of the filename. |