C
C
Coraelstraze2017-10-17 19:16:43
PHP
Coraelstraze, 2017-10-17 19:16:43

Menu from product characteristics in bitrix?

Good day!
There is an online store on Bitrix.
An unusual task was received from the customer: on the site, instead of a menu with sections, to make a kind of filter menu. Those. a menu in which, instead of sections, product characteristics will be displayed (just like in a horizontal filter), when you hover over them, a drop-down list opens - the products of which particular characteristics we want to view.
For example: menu item "Gender". We point at it and it drops out: "boy", "girl". We click on "boy" - we are thrown on goods for boys.
Roughly speaking, this is just a filter, but it needs to work exactly like a menu, without unnecessary "show elements". And not to conflict with other filters.
I got to the bottom of the .left.menu_ext.php file, in which I see that the sections are transferred to the $aMenuLinksExt array:

if($arIBlock["ACTIVE"] == "Y")
    {
      $aMenuLinksExt = $APPLICATION->IncludeComponent("bitrix:menu.sections", "", array(
        "IS_SEF" => "Y",
        "SEF_BASE_URL" => "",
        "SECTION_PAGE_URL" => $arIBlock['SECTION_PAGE_URL'],
        "DETAIL_PAGE_URL" => $arIBlock['DETAIL_PAGE_URL'],
        "IBLOCK_TYPE" => $arIBlock['IBLOCK_TYPE_ID'],
        "IBLOCK_ID" => $arIBlock['ID'],
        "DEPTH_LEVEL" => "3",
        "CACHE_TYPE" => "N",
      ), false, Array('HIDE_ICONS' => 'Y'));
    }

I understand that you can somehow customize it yourself, but I still don’t understand how to put characteristics in this design instead of sections.
Tell me, what are the solutions?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
L
Localhost, 2017-10-17
@selo

just make the name of the buttons as you want gender - male, and in the link you will make a link using the filter gender m or f

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question