Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fetching file listing using quatations doesn't work #7

Open
vekakela opened this issue Aug 26, 2011 · 1 comment
Open

Fetching file listing using quatations doesn't work #7

vekakela opened this issue Aug 26, 2011 · 1 comment
Labels
Milestone

Comments

@vekakela
Copy link

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.

@dereuromark
Copy link
Contributor

Is this still an issue?

@dereuromark dereuromark added this to the 2.x milestone Jan 22, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants