title: Check if a file matches a wildcarded spec, in a given directory, with PHP
body: <p>I have a directory that files are uploaded to, and I want to be able to display a download link if the file exists. The file however has to match a particular pattern as this is the identifier of who uploaded it.</p>
  
  <p>The pattern starts with /ClientFiles/ then it needs to find all files that starts with the user ID. So for example: /ClientFiles/123-UploadData.xls</p>
  
  <p>So it would need to look in the ClientFiles directory and find all files that start with '123-' no matter what comes after.</p>
  
  <p>Cheers</p>