Open Linux Forums
Like Ubuntu forums, except with beer.
Member
Joined: Sep 30 2018
Posts: 2

Hello. I downloaded a pdf with wget and hosted it on my webserver. The pdf came up as 403 forbidden. I had all the right permissions, ownership, .htaccess etc. I decided to copy the file with cp in hopes it would refresh whatever metadata was causing the problem. Sure enough it worked.

What would have been a more proper solution?

Member
avatar
Joined: Dec 31 2017
Posts: 114

I'd have used chmod

Member
avatar
Joined: Dec 31 2017
Posts: 114

Actually, chown would be more applicable

Member
Joined: Dec 20 2019
Posts: 2

Try accessing your website. If 403 forbidden error is resolved, then this means that your .htaccess file was corrupt. You can generate a fresh .htaccess file by logging into your WordPress admin area and going to Settings » Permalinks page