homepage Welcome to WebmasterWorld Guest from 54.235.16.159
register, free tools, login, search, pro membership, help, library, announcements, recent posts, open posts,
Become a Pro Member
Home / Forums Index / Code, Content, and Presentation / Apache Web Server
Forum Library, Charter, Moderators: Ocean10000 & incrediBILL & phranque

Apache Web Server Forum

    
Web Server ignoring .htaccess
Just stumped....
evinrude




msg:1514314
 12:51 am on Nov 2, 2001 (gmt 0)

Spent the better half of this day tryin' to figure this one out, and I'm betting it's something easy. Any other time I've dealt with htaccess or htpasswd, it's just simply worked out of the box. No changes or anything....

Now I'm working on a newly built Solaris 8 box with Apache 1.3.20. I didn't build it, but it all looks "in order." However, it seems to be ignoring anything in .htaccess. I'm trying to set up a password for a directory, and cgi-bin access. (An application we have is entirely cgi...no external files except some graphics and a style sheet) No errors, but I don't really expect any, it's simply ignoring .htaccess.

Any enlightenment? Anything else I could post that could be helpful?

 

littleman




msg:1514315
 2:58 am on Nov 2, 2001 (gmt 0)

Did you check read permissions?

bird




msg:1514316
 3:14 am on Nov 2, 2001 (gmt 0)

Check how the AllowOverride variable in the httpd.conf file is set. You can turn on (and off! ;)) specific .htaccess features there.

evinrude




msg:1514317
 6:26 pm on Nov 2, 2001 (gmt 0)

> Did you check read permissions?

Yeah, permissions on .htaccess and .htpasswd are set to read.

Here's what I've tried. I set the AllowOverride to AuthConfig.

If I have .htaccess in both cgi-bin and webroot, and then hit the cgi application, the page loads without asking for a password, but the content from the webroot (images, css, and javascript) fail to load. Removing the .htaccess from webroot results in a perfectly loaded page, but no request for password.

.htaccess looks like:
AuthUserFile /usr/local/apache/conf/.htpasswd
AuthGroupFile /dev/null
AuthName "App Name"
AuthType Basic
require valid-user

Gorufu




msg:1514318
 1:37 am on Nov 3, 2001 (gmt 0)

Hi evinrude,

The .htaccess file looks OK to me.

> Here's what I've tried. I set the AllowOverride to AuthConfig.

Did you restart Apache? When changes are made to httpd.conf srm.conf or access.conf Apache normally needs to be restarted for the changes to become effective.

Also check that AuthConfig was added to AllowOverride in the correct
<Directory /paths>

In many Apache setups there can be several <Directory> directives, including a separate one for cgi-bin

Puffin




msg:1514319
 1:18 pm on Nov 5, 2001 (gmt 0)

I had this problem, but I solved it by setting the .htaccess dir. in the config file.

There is a seperate directory setting for .htaccess files which is probably not the same as your webdocument directory. Check this out. I do not have my laptop with Apache with me at the moment so I can't check it out.

If you can't find this setting, reply and I'll take a look this evening.

Global Options:
 top home search open messages active posts  
 

Home / Forums Index / Code, Content, and Presentation / Apache Web Server
rss feed

All trademarks and copyrights held by respective owners. Member comments are owned by the poster.
Home ¦ Free Tools ¦ Terms of Service ¦ Privacy Policy ¦ Report Problem ¦ About ¦ Library ¦ Newsletter
WebmasterWorld is a Developer Shed Community owned by Jim Boykin.
© Webmaster World 1996-2014 all rights reserved