SC36DC Posted January 4, 2021 Posted January 4, 2021 On my forum, when I or any other member clicks on the Downloads item in the menu, the following message comes up,  Forbidden You don't have permission to access this resource. Apache/2.4.25 (Debian) Server at www.(site name).com Port 80 Would anyone know what would cause this to show up? Thanks.
Adriano Faria Posted January 4, 2021 Posted January 4, 2021 It’s a server (not application) error message so I would take a look in permissions. See: https://www.digitalocean.com/community/questions/forbidden-you-don-t-have-permissions-to-access-on-this-server https://stackoverflow.com/questions/10873295/error-message-forbidden-you-dont-have-permission-to-access-on-this-server SC36DC 1
Jock3r Posted January 5, 2021 Posted January 5, 2021 What Adriano sent above is most probably what is wrong. Do you mind sending us your apache config?
SC36DC Posted January 5, 2021 Author Posted January 5, 2021 10 minutes ago, Jock3r said: What Adriano sent above is most probably what is wrong. Do you mind sending us your apache config? Where is this file located? I just contacted Cloudways support, thought it was a htaccess file issue, they had this to say: Â Quote It seems like there is some application level restriction set from somewhere within the file, Please note that this is something beyond our standard support scope and reason behind is that we are not familiar with your application functionality at all, I would suggest you to contact your developer and ask him to check it for you, I hope you understand it. The only thing I did yesterday to my overall forum, as far as changes, was enable 'Rewrite URLs'. I had add the '.htaccess' file that is there to download, and added it to my forum on the server, is it possible I placed the file in the wrong location? Where should it be placed? The rewrite of the urls did work though. Â Â
Jock3r Posted January 5, 2021 Posted January 5, 2021 Your apache config is probably located here /etc/apache2/apache2.conf Was downloads application working fine prior to you enabling rewrite urls? The .htaccess file must be placed on the main directory of the forum
SC36DC Posted January 5, 2021 Author Posted January 5, 2021 2 minutes ago, Jock3r said: Your apache config is probably located here /etc/apache2/apache2.conf Was downloads application working fine prior to you enabling rewrite urls? The .htaccess file must be placed on the main directory of the forum I placed the file in the main directory of my forum, not the main directory of the server, my website.
Jock3r Posted January 5, 2021 Posted January 5, 2021 Just now, SC36DC said: I placed the file in the main directory of my forum, not the main directory of the server, my website. Yeah, that was precisely what I meant. Please provide the apache config whenever you can as well so we can assist you further.
SC36DC Posted January 5, 2021 Author Posted January 5, 2021 I can not find this anywhere on my server,  /etc/apache2/apache2.conf I can not find the '/etc' folder.Â
Jock3r Posted January 5, 2021 Posted January 5, 2021 Uhm, is it a managed server or do you do everything on your own? Managed means that the VPS/Dedicated Server you have is managed by employees of your hosting. SC36DC 1
SC36DC Posted January 5, 2021 Author Posted January 5, 2021 4 minutes ago, Jock3r said: Uhm, is it a managed server or do you do everything on your own? Managed means that the VPS/Dedicated Server you have is managed by employees of your hosting. Cloudways is managed, yes. https://www.cloudways.com/en/apache-hosting.php The thing is, my Downloads section was working just fine, until someone today messaged to let me know they couldn't access it. Â
Morrigan Posted January 5, 2021 Posted January 5, 2021 You enabled re-write URLS and that's what caused this? If you remove the htaccess and turn it off does it work again? SC36DC 1
SC36DC Posted January 5, 2021 Author Posted January 5, 2021 19 minutes ago, Morrigan said: You enabled re-write URLS and that's what caused this? If you remove the htaccess and turn it off does it work again? I tried it, and no, it does not work again.
Solution bfarber Posted January 5, 2021 Solution Posted January 5, 2021 Downloads uses the friendly URL path of "/files". Do you happen to have an actual folder on your server named "files"? If so, Apache would route the request to that folder and the request would never make it to our software - the solution would be to rename that folder to something else. Jock3r and Armas 2
SC36DC Posted January 5, 2021 Author Posted January 5, 2021 9 hours ago, bfarber said: Downloads uses the friendly URL path of "/files". Do you happen to have an actual folder on your server named "files"? If so, Apache would route the request to that folder and the request would never make it to our software - the solution would be to rename that folder to something else. Yes, the folder on my server was named 'files', I changed it to 'downloads', it is working again. Thanks @bfarber for the help.
Zone Plate Posted September 4, 2021 Posted September 4, 2021 On 1/5/2021 at 9:20 AM, bfarber said: Downloads uses the friendly URL path of "/files". Do you happen to have an actual folder on your server named "files"? If so, Apache would route the request to that folder and the request would never make it to our software - the solution would be to rename that folder to something else. Bingo! I had a related issue with an old app that I moved out of the folder as a copy. I would have never figured this out. Marc 1
Marc Posted September 5, 2021 Posted September 5, 2021 On 9/4/2021 at 4:23 PM, Zone Plate said: Bingo! I had a related issue with an old app that I moved out of the folder as a copy. I would have never figured this out. Glad to see you got what you needed there 🙂Â
Recommended Posts