title: Find duplicate files by names with PHP
body: <p>There are some modules in project which are being renamed or newly created or copied directly. Now I want to delete old directory files. So I want to find all files with their path which are having same name for clean up . (count > 2). That can be css, tpl, php or js files.</p>
  
  <p>i.e.</p>
  
  <pre><code>Main\Games\troy.php
  Main\Games\Child Games\troy.php
  Main\Games\Sports\troy.php
  </code></pre>
  
  <p>If search is done on Main directory then search should return all 3 files and their paths. How to find duplicate files by PHP.</p>
  
  <p>That will be useful also for finding duplicate files with same name in your drive like mp3, 3gp files. </p>