'<i>' и '</i>'
, то можно без всяких регулярок сделать двойной прогон:<i>
' на пустоту,</i>
' на пустоту."originalText":"<i>([^"]+)"
"originalText":"$1"
"originalText":"([^"]+)<\/i>"
"originalText":"$1"
<?php
$traceLog = __FILE__.":".__LINE__."\n";
$trace = debug_backtrace(DEBUG_BACKTRACE_IGNORE_ARGS);
foreach ( $trace as $tr ) {
if( !array_key_exists('file', $tr) ) continue;
$traceLog .= "{$tr['file']}:{$tr['line']}\n";
}
echo $traceLog;
<?php
if ( empty($arResult['VARIABLES']['SECTION_CODE'])
&& !empty($arResult['VARIABLES']['SECTION_PATH'])
&& CModule::IncludeModule('iblock') )
{
\Bitrix\Iblock\Component\Tools::process404(
""
,($arParams["SET_STATUS_404"] === "Y")
,($arParams["SET_STATUS_404"] === "Y")
,($arParams["SHOW_404"] === "Y")
,$arParams["FILE_404"]
);
}
<?php
if ( empty($arResult['VARIABLES']['SECTION_CODE'])
&& !empty($arResult['VARIABLES']['SECTION_PATH'])
&& CModule::IncludeModule('iblock') )
{
$parts = explode('/', $arResult['VARIABLES']['SECTION_PATH']);
$filter = ['IBLOCK_ID' => $arParams['IBLOCK_ID'], '=CODE' => array_pop($parts)];
$rs = CIBlockSection::GetList([], $filter, false, ['ID']);
if ( !$rs->Fetch() ) {
\Bitrix\Iblock\Component\Tools::process404(
""
,($arParams["SET_STATUS_404"] === "Y")
,($arParams["SET_STATUS_404"] === "Y")
,($arParams["SHOW_404"] === "Y")
,$arParams["FILE_404"]
);
}
}
nginx -t
grep -rl '.pem' /etc/nginx
if(!$componentPage)
{
$componentPage = "sections";
$b404 = true;
}
var_dump($b404, $componentPage, $arVariables); die;
var_dump($componentPage);
die;
$this->IncludeComponentTemplate($componentPage);