title: If-Statement Help in PHP
body: <p>So for some reason this just doesn't make sense to me. </p>
  
  <p><strong>What Im trying to do is display 1 of 2 things:</strong></p>
  
  <ol>
  <li>If the filesize of just 1 image in the folder is too big, display the error message I have  above. </li>
  <li>If all of the filesizes are ok, display a bit of HTML code</li>
  </ol>
  
  <p>Also, is my threshold correct if I want the limit to be 5MB?</p>
  
  <pre><code>&lt;?php
  $threshold = 5368709120;
  $path = 'dir/'.$username;
  foreach (glob($path."/{*.gif,*.jpg,*.jpeg,*.png}",GLOB_BRACE|GLOB_NOSORT) as $filename)  
  {
      $size = filesize($filename);
      if ($size &gt; $threshold) {
          exit('One or more of your photos are larger than 5MB. Resize your photos and try again.');
      }
  }
  ?&gt;
  </code></pre>