Finding file dupes by analyzing their contentFastDuplicateFinder is PHP class which quickly finds file duplicates. File names and extensions doesn't matter as it compares files byte by byte. It can scan subdirectories recursively
and it doesn't waste time comparing files of different sizes as they simply cannot be the same.
You can use, for example, to remove unnecessary files from your server and save some disk space this way. The code is pretty straightforward with some comments so if you need you can optimize further it's or add more features. If you do so and want to share your code with other people, let me know and I'll publish your updates here.
Installation and Usage
Just unpack the archive and include file FastDuplicateFinder.php in your code.
include 'FastDuplicateFinder.php'; $d = new FastDuplicateFinder; $results = $d->scan('kat', true); print_r($results);
Array (  => Array (  => kat\duplicate1a.PNG  => kat\subdir\duplicate1b.PNG )  => Array (  => kat\duplicate2a.txt  => kat\duplicate2b.txt ) )