Not sure if this is the right area for this issue, but hopefully someone can help.
I have a Drupal site on the Green Greeks server where you can password protect a folder and create as many user and passwords you like in the cPanel. The issue currently is when I set it up the protection, there apparently is a conflict with Drupal because when a user ID and password is entered it gives and error message that the page can't be found on this server. (Page not found
The requested page "/sites/default/files/Members/Member_Area.pdf" could not be found.)
I spoke to support at Green Greeks and they couldn't find the problem all they could say is it was a conflict with Drupal. I know I can create a basic password protection of the page, however this doesn't allow for different users with different passwords. It is important that each user has their own individual password because members come and go. We don't want to change the password every time someone leaves the organization. Does anyone have any idea how I can solve the issue?
Comments
Are you sure that you have
Are you sure that you have the correct path to the file? And if so, have you checked the permissions on the file? They should be 644 (rwx-r-r).
If you have clean URLs enabled:
Drupal has an .htaccess file in the folder that is used for the URL re-write, AKA Clean URLs. The rewrite rules that make the URL 'clean' are set up to not kick in if the path that the user has entered is an existing file. This means that Drupal doesn't 'turn on' (as it were), and instead lets the server do decide what to do with the file. The system has to be set up this way to allow for the system files, CSS files, and JS files to be usable. If the .htaccess file rewrite rules set these paths to be executed by Drupal, the system would break.
The message you gave, you are seeing that in a Drupal page, correct? This means that the system thinks that there isn't a file at that path. You need to figure out if there is not a file, or if there is a file, then why is Drupal overriding it?
You can probably download an extension for your browser (unless maybe if you are on IE) that will allow you to see the page headers for the page in question. This will include the headers, both sending and receiving, for the file in question, which will give you a place to start when trying to figure out how to debug your problem. I use Live HTTP Headers for firefox myself.
Jaypan We build websites
Creating several different user and passwords when using Passwor
Thank you for our comment. I do have clean urls setup and yes I am seeing the message in a Drupal page. Oddly enough I have a similar website that I have setup with password protection on another host and I seem to recall the host had to fix the .htaccess file and it resolved the issue. I had forgotten about that happening since that has been a few years ago until you just pointed it out.
The hosting site for the web page in question is "Green Greeks" and they originally gave me this answer as to why the issue was happening:
There is some conflict between the Drupal rules in the ".htaccess" file and "Password Protect Directories" of the cPanel. I have created the test folder /home/dshaorg/public_html/sites/default/files/Membertest and copied the pdf file to this directory. Please check the URL http://www.dsha.org/sites/default/files/Membertest/Member_Area.pdf and then go to the cPanel disable the "Password Protect Directories" feature for the "Membertest" folder and check the URL again.
There is nothing in the error_log of your web site or error_logs of the server that can explain that causes this problem.
Please check these URLs http://drupal.org/project/node_privacy_byrole http://drupal.org/project/content_access or try to find out how you can protect the file on the Drupal forum.
If I create a password protect on the actual page in Drupal I can only use one user and password when I need to have multiple users.
=-=
As you aren't writing a module, this question is better served in the post installation forum. Please edit the opening post and move it. Thanks.