-
Notifications
You must be signed in to change notification settings - Fork 19
Description
Fetching file listing using quatations doesn't seem to work (ie. if i try to list files in a folder that has spaces in the folder name):
ls "/home/username/Test folder"
This doesn't work:
$files = $this->Ftp->find('all', array('conditions' => array('path' => '"/home/username/Test folder"')));
and neither does this:
$files = $this->Ftp->find('all', array('conditions' => array('path' => '/home/username/Test folder')));
I could preformat the folder path to this:
/home/username/Test\ folder
but I prefer using the quatations, so I fixed the problem by changing the code in ftp_source.php from this:
$raw = $this->config['connection']->exec($cmd.$path);
to this by adding quatations around folder path:
$raw = $this->config['connection']->exec($cmd.'"'.$path.'"');
so that quatations are always placed around folder path.