|
|
|||||||||
|
|||||||||
| |||||||||
|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
.htaccess not working
Hello,
I have my .htaccess file in a directory but when I go to the directory it just lets me get in anyway - the .htaccess file is not working. The code in it is: AuthUserFile /usr/lib/apache/.htpasswd AuthGroupFile /dev/null AuthName extranet AuthType Basic <Limit GET POST> require valid-user </Limit> I am running Apache on Linux. Also, I can browse directories if I don't put in a filename. How do I switch this off please? Cheers James |
|
#2
|
|||
|
|||
|
do this to hide directory indexes
Options -Indexes as for your basic auth, it looks ok, maybe .htacces has been turned off on your server |
|
#3
|
|||
|
|||
|
How do you turn it back on again?
|
|
#4
|
||||
|
||||
|
>>How do you turn it back on again?
Check AllowOverride @ http://httpd.apache.org/docs/mod/co...l#allowoverride
__________________
My article: mod_rewrite: No More Endless Loops! |
|
#5
|
|||
|
|||
|
You need to tell Apache to give override permission to the directory where your .htaccess resides.
<Directory "/path/to/docroot/private"> Options -Indexes AllowOverride AuthConfig </Directory> |
![]() |
| Viewing: Dev Shed Forums > System Administration > Apache Development > .htaccess not working |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|