title: Iterate through a specific directory tree and store all the .ttf files into an array in PHP
body: <p>Lets say I have a lot of files, some of those are in these paths:</p>
  
  <pre><code>root/fonts/folder1/font1.ttf
  root/fonts/folder1/font2.ttf
  root/fonts/folder2/font1.ttf
  root/fonts/folder2/font2.ttf
  root/scripts/file.php
  </code></pre>
  
  <p>Remember that there are also other types of files in those folders. How can my <em>"/scripts/file.php"</em> iterate through the <em>"../fonts/"</em> directory tree and store all the TrueType font <em>(.ttf)</em> files into an array? Could you show me an example?</p>