Redirect from dotted pages
http://web-site.com/index.phpsad 404 page
http://web-site.com/404 Redirect from dotted pages
http://web-site.com/index.phpsad 404 page
http://web-site.com/404 It would be better to do so:
Redirecting the status code 301 to the page with the 404th error is wrong . It does not have the most similar content that does not exist now. You should immediately return the 404th error when accessing such addresses. Gluing non-existing addresses with the 404th error will not give anything in SEO.
HTTP status codes do not just exist, this is a standard that should be followed.
In the description of the standard and on the wiki you will find more information.
Read the article from Google: " Do 404s hurt my site? "
RewriteEngine On RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule [.] /404 [L] This will process all pages that contain a dot in their address, except for existing files and folders with a dot in their name.
An example of the script:
/test.sub/ # Не существующий раздел - 404 Not Found /test.h # Не существующий файл - 404 Not Found /catalog.example/ # Существующий раздел - 200 OK /index.html # Существующий файл - 200 OK The answer used the information from the answer to the question: " SEO - 301 redirect via 404 page "
Source: https://ru.stackoverflow.com/questions/529876/
All Articles