Answer the question
In order to leave comments, you need to log in
Why does the server give a 404 error, but still show the requested page?
Good afternoon.
There is a site under development, the CNC is configured via mod_rewrite.
htaccess is the following:
RewriteEngine On
## add slash
RewriteBase /
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_URI} !(.*)/$
RewriteRule ^(.*[^/])$ $1/ [L,R=301]
## main rule
RewriteRule ^_dev/([^/]*)\/$ /_dev/index.php?route=$1 [L]
# blog child
RewriteRule ^_dev/blog/([^/]*)\/$ /_dev/index.php?route=blogpost&showpost=$1 [L]
# services child
RewriteRule ^_dev/services/([^/]*)\/$ /_dev/index.php?route=servicecat&filter=$1 [QSA,L]
RewriteRule ^_dev/services/([^/]*)/([^/]*)\/$ /_dev/index.php?route=servicepost&cat=$1&showpost=$2 [L]
Answer the question
In order to leave comments, you need to log in
come on site.
This is usually a bug in the code.
Turn off everything on the main page piece by piece, see when the 404 disappears.
But if it no longer disappears on a clean html page, then there are really problems.
You can, as an option, put index.html and disable index.php
if, for all equal, it will give 200, then there really is a problem in the code.
ps. seen this a couple of times
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question