A
A
alex9212018-08-17 11:37:41
1C-Bitrix
alex921, 2018-08-17 11:37:41

How to set the page PAGEN_1 - /page1/ instead of the parameter?

Hello! I need to remove the section description on pagination pages. Here I was given the following code:

<? if (!isset($_REQUEST['PAGEN_1']) || $_REQUEST['PAGEN_1'] == 1): ?>
  <?if($arResult["DESCRIPTION"]!=""):?>
   <div class="wrapper"><?echo $arResult["DESCRIPTION"]?></div>
  <?endif;?>
<?endif;?>

But it doesn’t suit me so pagination is displayed not site.ru/catalog/category/?PAGEN_1=2 but site.ru/catalog/category/page2/ (page3,page4,page5 etc.
) this line - <? if (!isset($_REQUEST['PAGEN_1']) || $_REQUEST['PAGEN_1'] == 1): ?>

Answer the question

In order to leave comments, you need to log in

2 answer(s)
E
Evgeny Kuzovlev, 2018-08-17
@Kiyoshi

<? if (!preg_match('/page\d+/')): ?>

A
Alexander, 2018-08-17
@idruweb

<? if ($arResult["NAV_RESULT"]->NavPageNomer==1):?>
<?if($arResult["DESCRIPTION"]!=""):?>
<?echo $arResult["DESCRIPTION"]?>
<?endif;?>
<?endif?>

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question