Hello and welcome to our community! Is this your first visit?
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 1 of 1
  1. #1
    New Coder
    Join Date
    Feb 2009
    Thanked 0 Times in 0 Posts

    htaccess and AllowOverride


    I know that .htaccess won't work when AllowOverride = None, but I'm just having trouble why one directory in my web server can use htaccess. I want to create a login prompt using htaccess and htpasswd.

    sample 1 (this one is working):

    this sample works and propely show and ask for user authentication.

    path : /usr/local/apache/htdocs/mis/folder_1/
    AuthType Basic
    AuthName "Restricted Access"
    AuthUserFile /usr/local/apache/htdocs/mis/folder_1/.htpasswd
    Require user testuser
    sample 2:

    so i created another folder under the mis and named it folder_2, copied the .htaccess and .htpasswd from folder_1 but every time i visit the site it does not show the login prompt.

    any idea why this is happening?


    ok nvm, i found out by browsing the .conf, the previous user assigned the directory.
    <Directory "/usr/local/apache/htdocs/mis/folder_1">
        Options Indexes FollowSymLinks
        AllowOverride AuthConfig
        Order allow,deny
        Allow from all
    oh well, now its gonna be a problem since if i add my folder i would have to restart the server which most likely will not be allowed
    Last edited by RamaJin; 03-16-2010 at 05:34 AM. Reason: solved


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts