Forum Moderators: phranque

Message Too Old, No Replies

enabling .htaccess

seems to be disabled on the server...

         

IPfreely

1:42 pm on Oct 8, 2004 (gmt 0)

10+ Year Member



hello!
i am trying password protect a directory but no matter what combination i enter into .htaccess and .htpasswd nothing works which got me thinking maybe .htaccess hasn't been enabled!
after more research i see that some stuff might have to be entered into the httpd.conf file, right? i did a search on the server and httpd.conf came up in 11 places. which one do i change?

info:
i have root access, this is our webserver (no shared or virtual accounts)
here are the files:
******************************************
/etc/admserv/conf/httpd.conf
/etc/admserv/conf/httpd.conf.master
/etc/admserv/conf/httpd.conf.pkgsave
/etc/admserv/conf/httpd.conf.master.pkgsave
/etc/httpd/conf/httpd.conf
/etc/httpd/conf/httpd.conf.master
/etc/httpd/conf/httpd.conf.pkgsave
/etc/httpd/conf/httpd.conf.master.pkgsave
/etc/httpd/conf/httpd.conf.sav
/usr/local/etc/httpd.ourSiteName/conf/httpd.conf
/usr/local/etc/httpd.ourSiteName/conf/httpd.conf.orig

thanks!
IPfreely

jdMorgan

4:58 pm on Oct 8, 2004 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



/usr/local/etc/httpd.ourSiteName/conf/httpd.conf

is where you'll need to make sure that mod_rewrite is loaded, and that AllowOverrides and Options are set up to allow it to work for your site.

Jim

SkyDog

12:47 am on Oct 10, 2004 (gmt 0)

10+ Year Member



If you have root access, just put the authorization directive in the httpd.conf file rather than adding and AllowOverride directive and an .htaccess file.

IPfreely

1:38 pm on Oct 12, 2004 (gmt 0)

10+ Year Member



sorry guys i've been out sick but i'm back @ work. jdMorgan -what is mod_rewrite? i see it written in httpd.conf as:
"LoadModule rewrite_module modules/mod_rewrite.so"

If you have root access, just put the authorization directive in the httpd.conf file rather than adding and AllowOverride directive and an .htaccess file.

how do i go about doing that? and can i assume the reason to do that would be to avoid a performance hit?

thanks guys,
IPfreely

coopster

1:49 pm on Oct 12, 2004 (gmt 0)

WebmasterWorld Administrator 10+ Year Member




jdMorgan -what is mod_rewrite? i see it written in httpd.conf as:
"LoadModule rewrite_module modules/mod_rewrite.so"

That would be it. You'll find some good links regarding mod_rewrite in the Apache Forum Charter [webmasterworld.com].


how do i go about doing that? and can i assume the reason to do that would be to avoid a performance hit?

There is an Apache Tutorial: .htaccess files [httpd.apache.org] that offers some fairly good direction.

IPfreely

4:59 pm on Oct 12, 2004 (gmt 0)

10+ Year Member



thanks for the info! i'm having a read through right now and this looks like what i'm looking for. seems i don't even need to use .htaccess....
- IPfreely