fanfavorite Posted January 20, 2007 Share Posted January 20, 2007 I have a site that is password protected using php/mySQL. This works fine, but I want to have the directories protected. I have thought about putting them outside the public_html folder, however I don't believe I can do this the way I have everything setup. Basically I have an Admin area that allows the administrator to add users and upload the content in zip format. It extracts it on the server, etc into a specified directory and a page is setup in the members area to read in all of the uploaded data. So I don't believe there is a way for me to have it extract the data in an outside directory or that would be a security issue right? I also don't want to go the route of .htpasswd, so I tried to use .htaccess to access the mySQL database to check for the username, however my host does not have a module mod_auth_mysql and won't install it. My question is, is there an alternative to mod_auth_mysql that my host might have? Or do you have any suggestions as to what I should do? Any help on this issue would be greatly appreciated. Thanks!-JC Quote Link to comment https://forums.phpfreaks.com/topic/34960-solved-alternative-to-mod_auth_mysql/ Share on other sites More sharing options...
fanfavorite Posted January 27, 2007 Author Share Posted January 27, 2007 Well thanks to all who viewed and tried to help. My workaround is adding the following into my htaccess file:SetEnvIf Referer mydomain.com internal<Limit GET POST>order deny,allowdeny from allallow from env=internal</LIMIT>This doesn't allow anyone to type in the direct url, but allows the images to display on the members page. Quote Link to comment https://forums.phpfreaks.com/topic/34960-solved-alternative-to-mod_auth_mysql/#findComment-170652 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.