Search code examples
phpsymfonyftpsymfony-3.3

Symfony finder, Ignore dot files doesn't work with FTP address


I'm using Symfony, and the component Finder. I want to get a file whose name begins with dot (".file.txt") and this file is in other server.

If I do this:

$finder
    ->files()
    ->ignoreDotFiles(false)
    ->in("ftp://user:[email protected]:/myDir/")
;
  1. I don't get any file but, if I rename the file and remove dot ("file.txt") then I can find it.
  2. If I try to find files that start with dot in my local computer then it finds it well. Like here

So my question is: Why the method ignoreDotsFile doesn't works when is ftp address?


Solution

  • The code is very simple and clear, so if does not work is by a bug of Finder + FTP component.

    In fact FTP causes a lot of bugs like these:

    Options not working

    Bad performance

    More

    If connects with a windows machine this code would work fine but the problem was with linux server.

    Answer provided by: Javier Eguiluz