Answer the question
In order to leave comments, you need to log in
How to turn 403 always into 301 on home page?
There was a task to always turn 403 response on the site into 301 on the main page, is it possible to do this? Site if that on DLE
Answer the question
In order to leave comments, you need to log in
First you need to find all the files where these 403 or 301 errors are generated.
For example, for the full news show.full.php
Find
@header( "HTTP/1.1 403 Forbidden" );
Insert below
This is a redirect to the main page: header('Location: /');
If you want to another page, it will be like this:header('Location: /file.html');
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question