Page 1 of 1

Non existing and undeletable folder appears with readdir()

Posted: Mon Aug 22, 2011 3:57 am
by tehhparadox
Hi all

In my script I use opendir and readdir to get a list of folders in a specific directory.
However, someone created a folder which seems to be non existing, and I can't read the files in it or delete it.
That 'ghost' folder is listed in readdir(), as well as inside its parent folder in Filezilla.
However, trying to unlink() the folder throws "No such file or directory" error, and trying to delete it from Filezilla also throws an error saying "Failed to retrieve directory listing".
What can I do to delete this?

Thanks

Re: Non existing and undeletable folder appears with readdir

Posted: Mon Aug 22, 2011 4:48 am
by phphelpme
If you cant delete it with your ftp software, or your control panel built in ftp functions and your scripts can not either find it nor delete it then contact your hosting provider and ask them what this folder is because it could be something they have created or it could be an error on your account.

I get this sometimes and it turns out that my FTP program has not refreshed my server image correctly so I have to restart the FTP software to solve the issue.

Best wishes