I backed up my media files, and then started getting errors on my media:
Forbidden - You don't have permission to access /media/horseshoe_bend_war_1813-14.jpg on this server.
Additionally, a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the request.
Apache/1.3.42 Server at www.adkins9.net Port 80
As an example - root is www.adkins9.net, and image http://www.adkins9.net/media/horseshoe_bend_war_1813-14.jpg
I double-checked, the file IS there. I double-checked my permissions: media, media/thumbs, index, index/media, index/media/thumbs were wrong(?,) but now are all 777. Enable multimedia - yes, and as a precaution changed media firewall - no.
Still no joy. I did something wrong, but can't figure it out. Help, please.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
This is a permissions problem on the actual file, not on the directory. It looks as if you might have uploaded the file to the media directory using a tool like FTP instead of using the media upload facility built into PGV.
The individual files need 755 permission. On some servers, you can get away with 644. Mine insists on 755. 755 is never wrong.
You're getting the "404 not found" error because the .htaccess file in the ./media directory is not constructed properly. To fix this, you need to enable the media firewall, and then use the Manage Media page to move all media files to the protected media directory. This will re-build the .htaccess file. It might be wise to move everything from the protected media directory to the unprotected one, and then move everything back again.
If you want to stop using the media firewall, you need to use the Manage Media page to move everything to the regular media directory before disabling the media firewall.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Gerry: Although I couldn't define it, I was almost certain what had gone wrong, and who would nail it on the head.
That's exactly what I did wrong, however the solution does not quite seem to work. If it's okay, I will email you separately.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Yikes! Finally found it, and as Gerry predicted - I copied another .htaccess file from a pending webtress installation to read:
######## BEGIN WT MEDIA FIREWALL SECTION ##########
################## DO NOT MODIFY ###################
## THERE MUST BE EXACTLY 11 LINES IN THIS SECTION ##
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule .* /mediafirewall.php
</IfModule>
ErrorDocument 404 /webtrees/mediafirewall.php
########## END WT MEDIA FIREWALL SECTION ##########
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I backed up my media files, and then started getting errors on my media:
As an example - root is www.adkins9.net, and image http://www.adkins9.net/media/horseshoe_bend_war_1813-14.jpg
I double-checked, the file IS there. I double-checked my permissions: media, media/thumbs, index, index/media, index/media/thumbs were wrong(?,) but now are all 777. Enable multimedia - yes, and as a precaution changed media firewall - no.
Still no joy. I did something wrong, but can't figure it out. Help, please.
This is a permissions problem on the actual file, not on the directory. It looks as if you might have uploaded the file to the media directory using a tool like FTP instead of using the media upload facility built into PGV.
The individual files need 755 permission. On some servers, you can get away with 644. Mine insists on 755. 755 is never wrong.
You're getting the "404 not found" error because the .htaccess file in the ./media directory is not constructed properly. To fix this, you need to enable the media firewall, and then use the Manage Media page to move all media files to the protected media directory. This will re-build the .htaccess file. It might be wise to move everything from the protected media directory to the unprotected one, and then move everything back again.
If you want to stop using the media firewall, you need to use the Manage Media page to move everything to the regular media directory before disabling the media firewall.
Gerry: Although I couldn't define it, I was almost certain what had gone wrong, and who would nail it on the head.
That's exactly what I did wrong, however the solution does not quite seem to work. If it's okay, I will email you separately.
Yikes! Finally found it, and as Gerry predicted - I copied another .htaccess file from a pending webtress installation to read:
######## BEGIN WT MEDIA FIREWALL SECTION ##########
################## DO NOT MODIFY ###################
## THERE MUST BE EXACTLY 11 LINES IN THIS SECTION ##
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule .* /mediafirewall.php
</IfModule>
ErrorDocument 404 /webtrees/mediafirewall.php
########## END WT MEDIA FIREWALL SECTION ##########
I should have suggested that you delete the existing .htaccess file before doing that media firewall and moving of media files thing.
I know that the media firewall will create a .htaccess file if it's missing. It's been a looooong time since I last looked at that code.