title: download mp3 instead of playing in browser by default?
body: <p>I have a site where users can stream my music from a flash player or download the individual songs (as mp3s).  Right now if you click on the download links, they just play in the browser.  Can I make it so the download box will pop up by default without either zipping the files making the user rt. click?</p>
  
  <p>I have my index.php page with the links looking like this (pulling file names dynamically from mySQL:</p>
  
  <pre><code>&lt;table&gt;
  .
  .
  .
  &lt;td&gt;
      &lt;?php include 'Media/' . $row['type'] . '/' . $row['folder_name'] . '/download.php' ?&gt;
  &lt;/td&gt;
  </code></pre>
  
  <p>and then download.php has this:</p>
  
  <pre><code>&lt;div class="downloadCell"&gt;
      &lt;h3&gt;Downloads:&lt;/h3&gt;
      &lt;ul&gt;
          &lt;li&gt;
            &lt;a href="auto_download.php?path=Media/&lt;?php echo $row['type'] . '/' . $row['folder_name'] ?&gt;/Chemtengure.mp3"&gt;Chemtengure&lt;/a&gt;
          &lt;/li&gt;
      &lt;/ul&gt;
  &lt;/div&gt;
  </code></pre>
  
  <p>and I put the auto_download.php in the same directory as index.php:</p>
  
  <p>auto_download.php:</p>
  
  <pre><code>$path = $_GET['path'];
  header('Content-Disposition: attachment; filename=' . basename($path));
  readfile($path);
  </code></pre>