title: .htaccess Password protection keeps asking for password over and over
body: <p>I've placed this code in the <code>.htaccess</code> file of the folder I want to protect:</p>
  
  <pre><code>AuthName "restricted area"
  AuthType Basic
  AuthUserFile /home/#/#/#/#/#/.htpasswd
  require valid-user
  </code></pre>
  
  <p>In the same folder, I placed this <code>.htpasswd</code>:</p>
  
  <pre><code>my:pass
  </code></pre>
  
  <p>When I go to the URL of the protected folder, the browser keeps asking me for a password over and over, even though I'm typing the correct one.</p>
  
  <p>I know that the root directory mentioned in <code>AuthUserFile</code> is ok because I've found it out with:</p>
  
  <pre><code>&lt;?php
      $dir = dirname(__FILE__);
      echo "&lt;p&gt;Full path to a .htpasswd file in this dir: " . 
          $dir . "/.htpasswd" . "&lt;/p&gt;";
  ?&gt;
  </code></pre>
  
  <p>Where's the problem?</p>