title: Dynamically creating zip with php
body: <p>What is the easiest way of creating dynamically zip files with php?</p>
  
  <p>For example,</p>
  
  <p>I have these files on the server,</p>
  
  <pre><code>Root -&gt; Folder 1 -&gt; file1.wav
  Root -&gt; Folder 2 -&gt; file2.jpg 
  </code></pre>
  
  <p>I want to create a zip file contains these 2 files and allow user to download it.</p>
  
  <p>any help ?</p>
  
  <p>Thx in advance</p>