Cancel $APPLICATION->ShowViewContent on condition
Rus
Eng
Отменить $APPLICATION->ShowViewContent
I solve complex technical challenges for Bitrix and 1C—ranging from auditing existing code to configuring complex integrations—with a guarantee of results.
Recommended

Website hosting

If you are choosing hosting for your project, I recommend Timeweb. Modern infrastructure, a wide range of plans from starter options to high-load VPS, and responsive tech support that actually helps instead of sending template replies. I host some of my own projects there and recommend it to my clients.

Go to site Affiliate link. The price remains the same for you.

All English-language materials have been translated fully automatically using the Google service

Typical application situation when using the CNC sotbit on the Aspro Max. When, with the bottom description filled in the sotbit rule, you need to disable the output of the standard bottom description

Lower SEO descriptions are called in \local\templates\aspro_max_updated\components\bitrix\catalog\main\page_blocks\list_elements_1.php and similar ones in the block:

$APPLICATION->ShowViewContent('bottom_desc');
$APPLICATION->ShowViewContent('smartseo_bottom_description');
$APPLICATION->ShowViewContent('smartseo_additional_description');
$APPLICATION->ShowViewContent('sotbit_seometa_bottom_desc');
$APPLICATION->ShowViewContent('sotbit_seometa_add_desc');

Resetting $APPLICATION->ShowViewContent is simple. It is enough to do:

unset($GLOBALS['APPLICATION']->__view['bottom_desc'])

But to cancel the output of the base section description, we have to go to \bitrix\modules\aspro.max\classes\general\CMax.php, find the function setCatalogSectionDescription and in add the very end

if($sotbit_bottom_desc)
      unset($GLOBALS['APPLICATION']->__view['bottom_desc']);

Traditionally, I warn you that you do not need to change the core of the project and plugins. You do this at your own risk

Aleksandr Tichiy
Author

Aleksandr Tichiy

Fullstack developer · 1C-Bitrix

I build and modernize online stores and corporate portals on 1C-Bitrix. Integrations with 1C, high-load performance, 152-FZ compliance. Writing about architecture and e-commerce.


Comments

There are no comments yet, you can be the first to leave it

Leave a comment

The site uses a comment pre-moderation system, so your message will be published only after approval by the moderator

You are replying to a user's comment

Send

FEEDBACK

Email me

Please message me to discuss the task. I work remotely and officially (as a self-employed professional); my hourly rate is 1,800 RUB, and I can dedicate 3–4 hours a day to the project. I respond quickly, and the consultation is free.

An error occurred while sending, please try again after a while
Message sent successfully

Phones

+7(993) 007-18-96

Email

info@tichiy.ru

Address

Россия, г. Москва

By submitting the form, you automatically confirm that you have read and accept the Privacy Policy site