Voting

: four minus two?
(Example: nine)

The Note You're Voting On

Victor
12 years ago
If you are using Mac, or others systems that store information about the directory layout and etc, the function:

function empty_dir($dir) {
if (($files = @scandir($dir)) && count($files) <= 3)
return true;
else
return false;
}

Must have the count($files) comparing with the number of hidden files!

For example, I'm using Mac and the empty directory shows me three files: ".", ".." and ".DS_Store", so if I am planning to put the website online on my Mac, I've to count in the ".DS_Store" file!

<< Back to user notes page

To Top