Answer the question
In order to leave comments, you need to log in
Instead of a 404 error, a 301 redirect?
Good afternoon, instead of 404 errors and showing the page, Bitrix redirects to a higher level:
site/catalog/fdjksnfdksjnfkjsd -> site/catalog (301)
site/dkfmskld -> site (301)
site/contacts/randomstring2______ -> site/contacts (301)
ErrorDocument 404 /404.php
include_once($_SERVER['DOCUMENT_ROOT'].'/bitrix/modules/main/include/urlrewrite.php');
CHTTP::SetStatus("404 Not Found");
@define("ERROR_404","Y");
require($_SERVER["DOCUMENT_ROOT"]."/bitrix/header.php");
$APPLICATION->SetTitle("Страница не найдена");
его не существует
<?
$arUrlRewrite = array(
array(
"CONDITION" => "#^/bitrix/services/ymarket/([\\w\\d\\-]+)?(/)?(([\\w\\d\\-]+)(/)?)?#",
"RULE" => "REQUEST_OBJECT=\$1&METHOD=\$4",
"ID" => "",
"PATH" => "/bitrix/services/ymarket/index.php",
),
array(
"CONDITION" => "#^/personal/history-of-orders/#",
"RULE" => "",
"ID" => "bitrix:sale.personal.order",
"PATH" => "/personal/history-of-orders/index.php",
),
array(
"CONDITION" => "#^/acrit.exportproplus/(.*)#",
"RULE" => "path=\$1",
"ID" => "",
"PATH" => "/acrit.exportproplus/index.php",
),
array(
"CONDITION" => "#^/bitrix/services/ymarket/#",
"RULE" => "",
"ID" => "",
"PATH" => "/bitrix/services/ymarket/index.php",
),
array(
"CONDITION" => "#^/acrit.exportpro/(.*)#",
"RULE" => "path=\$1",
"ID" => "",
"PATH" => "/acrit.exportpro/index.php",
),
array(
"CONDITION" => "#^/contacts/stores/#",
"RULE" => "",
"ID" => "bitrix:catalog.store",
"PATH" => "/contacts/stores/index.php",
),
array(
"CONDITION" => "#^/contacts/stores/#",
"RULE" => "",
"ID" => "bitrix:news",
"PATH" => "/contacts/stores/index.php",
),
array(
"CONDITION" => "#^/personal/order/#",
"RULE" => "",
"ID" => "bitrix:sale.personal.order",
"PATH" => "/personal/order/index.php",
),
array(
"CONDITION" => "#^/info/articles/#",
"RULE" => "",
"ID" => "bitrix:news",
"PATH" => "/info/articles/index.php",
),
array(
"CONDITION" => "#^/company/news/#",
"RULE" => "",
"ID" => "bitrix:news",
"PATH" => "/company/news/index.php",
),
array(
"CONDITION" => "#^/info/article/#",
"RULE" => "",
"ID" => "bitrix:news",
"PATH" => "/info/article/index.php",
),
array(
"CONDITION" => "#^/catalogtest/#",
"RULE" => "",
"ID" => "bitrix:catalog",
"PATH" => "/catalogtest/index.php",
),
array(
"CONDITION" => "#^/info/brands/#",
"RULE" => "",
"ID" => "bitrix:news",
"PATH" => "/info/brands/index.php",
),
array(
"CONDITION" => "#^/info/brand/#",
"RULE" => "",
"ID" => "bitrix:news",
"PATH" => "/info/brand/index.php",
),
array(
"CONDITION" => "#^/products/#",
"RULE" => "",
"ID" => "bitrix:catalog",
"PATH" => "/products/index.php",
),
array(
"CONDITION" => "#^/services/#",
"RULE" => "",
"ID" => "bitrix:news",
"PATH" => "/services/index.php",
),
array(
"CONDITION" => "#^/support/#",
"RULE" => "",
"ID" => "altasib:support",
"PATH" => "/support/index.php",
),
array(
"CONDITION" => "#^/test-bx/#",
"RULE" => "",
"ID" => "bitrix:catalog",
"PATH" => "/test-bx/index.php",
),
array(
"CONDITION" => "#^/project/#",
"RULE" => "",
"ID" => "bitrix:catalog",
"PATH" => "/project/index.php",
),
array(
"CONDITION" => "#^/news/#",
"RULE" => "",
"ID" => "bitrix:news",
"PATH" => "/news/index.php",
),
array(
"CONDITION" => "#^/sale/#",
"RULE" => "",
"ID" => "bitrix:news",
"PATH" => "/sale/index.php",
),
array(
"CONDITION" => "#^/#",
"RULE" => "",
"ID" => "bitrix:catalog",
"PATH" => "/catalog/index.php",
),
array(
"CONDITION" => "#^/#",
"RULE" => "",
"ID" => "bitrix:catalog",
"PATH" => "/catalog_test1/index.php",
),
);
?>
Не существует
Answer the question
In order to leave comments, you need to log in
init.php
urlrewrite.php
look most likely here
array(
"CONDITION" => "#^/#",
"RULE" => "",
"ID" => "bitrix:catalog",
"PATH" => "/catalog/index.php",
),
array(
"CONDITION" => "#^/#",
"RULE" => "",
"ID" => "bitrix:catalog",
"PATH" => "/catalog_test1/index.php",
),
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question