title: Using htaccess, how to restrict seeing directory contents, but allow server to use the contents?
body: <p>More specifically, I have an htaccess file that restricts anyone from seeing the directory contents. Such that, nobody can see my 1000s of images in www.example.com/images by using:</p>
  
  <pre><code>deny from all
  allow from 127.0.0.1
  </code></pre>
  
  <p>However, I want to use these images on www.example.com such that, 
  <code>&lt;img src="images/thisimg.jpg" /&gt;</code> works.</p>
  
  <p>I hope I'm in the right direction, but I appreciate any insight/re-direct. This is similar to: <a href="https://stackoverflow.com/questions/4390876/how-to-protect-all-directory-contents-but-gain-access-to-php-script">How to protect all directory contents, but gain access to php script</a> but I want to link to these images in that directory, and using <code>deny from all</code> does not allow me to do that. </p>
  
  <p>Thanks in advance for your help.</p>