V
V
VicTHOR2019-10-10 16:28:44
Search Engine Optimization
VicTHOR, 2019-10-10 16:28:44

What to do with catalog pagination on Bitrix?

There is only one head everywhere, the catalog component is connected, and the catalog has pagination, which is made on GET requests, the catalog receives these GET pages and builds content .. Is it possible
to set canonical links in the catalog?

Answer the question

In order to leave comments, you need to log in

2 answer(s)
V
VicTHOR, 2019-10-11
@VicTHOR

Added this to the result_modifier of the catalog:section component

CMain::IsHTTPS() ? $s = 's' : $s = '';
$canonical = "http$s://www.".SITE_SERVER_NAME.$APPLICATION->GetCurPage();
$APPLICATION->AddHeadString('<link href="' . $canonical . '" rel="canonical" />', true);

Where $APPLICATION is a CMain object

D
David Koyava, 2019-10-10
@amarial

Any component can be customized based on what you are using. And in it already set your parameters that are necessary. https://dev.1c-bitrix.ru/learning/course/?CHAPTER_...

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question