cancel
Showing results for 
Search instead for 
Did you mean: 

php files in password protected folder not working on new CGI platform

Vega
Rising Star
Posts: 114
Thanks: 13
Registered: ‎22-06-2009

php files in password protected folder not working on new CGI platform

Hi
I've been sifting through my site on the new CGI platform. So far, so good, website displaying properly and php scripts seem to be updated with new crudentials etc.
The only issue I'm having is with a htaccess protected folder (called *domain*/upload/) that I used on the old platform to upload data to my database via php scripts. Its giving me an 500 internal server error when trying to access it. Looking at the folder via FTP, it shows the .htaccess and .htpasswd files in there fine.
Is there anything I should be doing to this folder?  Also, in future, would these scripts be better served in the private folder? (Im not sure how the private folder functions, is it different?)
Apologies for all the questions!
Regards
3 REPLIES 3
spraxyt
Superuser
Superuser
Posts: 10,063
Thanks: 1,369
Fixes: 75
Registered: ‎06-04-2007

Re: php files in password protected folder not working on new CGI platform

Does this work if you disable the .htaccess and .htpasswd files?
Is /upload at domain root level (/upload) as you seem to imply or within the webroot (/public/upload)?
/private is used by the system (eg to hold phpMyAdmin configuration data). In my opinion it is best for users to avoid it (and /databases even more so).
David
David
Vega
Rising Star
Posts: 114
Thanks: 13
Registered: ‎22-06-2009

Re: php files in password protected folder not working on new CGI platform

Apologies it's in (/public/upload)
I've noticed something. Had to change the absolute path on .htaccess file and re-upload. Now the username and password promt comes up as expected but password not working. Should I assign any special permissions to .htpasswd ?
spraxyt
Superuser
Superuser
Posts: 10,063
Thanks: 1,369
Fixes: 75
Registered: ‎06-04-2007

Re: php files in password protected folder not working on new CGI platform

Both the .htaccess and .htpasswd files in a restricted directory of mine have chmod permissions of 640 and access control works fine.
This is unlikely to be the problem since a username and password are requested but was the upload done in ASCII mode?
David
David