Invision Community 4: SEO, prepare for v5 and dormant account notifications By Matt Monday at 02:04 PM
ipbfuck Posted March 10, 2016 Posted March 10, 2016 Hi, if i go in a directory without a file inderx, eg: https://laltroweb.it/test i receive a loop redirect cause from this code by ipb in htaccess: Quote RewriteCond %{REQUEST_FILENAME} !-f RewriteRule \.(js|css|jpeg|jpg|gif|png|ico)(\?|$) /404error.php [L,NC] RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule . /index.php [L] if i remove, all work again (i receive a simple forbidden by my server - cause global "no directory index" in my root htaccess. someone can help me to fix this? :| thanks, S.N.
tnn Posted March 10, 2016 Posted March 10, 2016 If you are on a server where you can control indexing, you might want to set your folder to "No Indexing" and see if that helps. You can control it through cPanel if you have that or through an .htaccess file. Options are: No Indexing Standard Indexing (filename only) Fancy Indexing (filename and description)
ipbfuck Posted March 11, 2016 Author Posted March 11, 2016 like i've write: Quote if i remove, all work again (i receive a simple forbidden by my server - cause global "no directory index" in my root htaccess. then, thanks for reply, but i already have No Indexing in entire root
tnn Posted March 11, 2016 Posted March 11, 2016 Ahh, okay... I missed that. After all my loop problems at the beginning, I can't seem to duplicate what you have. Hopefully someone can help you.
ipbfuck Posted March 11, 2016 Author Posted March 11, 2016 Ok, thanks for reply! Maybe something missing in php config, but all request from ipb is valid... then, i don't know :/
ipbfuck Posted March 11, 2016 Author Posted March 11, 2016 Ok, fixed now 403error.php in root directory: (like default output server page and based on default 404error page from ipb) <?php header("HTTP/1.0 403 Forbidden"); $uri = $_SERVER["REQUEST_URI"]; print <<<EOF <html> <title>403 Forbidden</title> <body> <h1>Forbidden</h1> <p>You don’t have permission to access $uri on this server.</p> <p>Additionally, a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the request.</p> </body> </html> EOF; exit; and: ErrorDocument 403 /403error.php in htaccess (at the end). Now all is good
Recommended Posts
Archived
This topic is now archived and is closed to further replies.