I
I
IvanRobot2016-04-19 09:38:35
1C-Bitrix
IvanRobot, 2016-04-19 09:38:35

How does bitrix determine the path to the component?

dir_index template is used for index.php file

9066b9dad42c4b5b9fcb0a06056a7125.png

/local/templates/dir_index/header.php

require($_SERVER['DOCUMENT_ROOT'] . DIR_TEMPLATE_PATH . '/header.php');

/local/php_interface/s1/init.php

define("DIR_TEMPLATE_PATH", '/local/templates/dir_common');

14c7b31c893440a596a08888cda4e181.png

/local/templates/dir_index/header.php

// в этом файле есть включение компонента, но в данной директории нет никаких компонентов..
$APPLICATION->IncludeComponent("bitrix:menu", "leftmenu", Array(

Answer the question

In order to leave comments, you need to log in

1 answer(s)
S
Sergey, 2016-04-19
@IvanRobot

bitrix:menu -
bitrix - namespace
menu - component name (component folder name)
leftmenu - template name.
It is defined as follows: it is searched in local in the template of the current site, then in the default template, then it is searched in /bitrix/tempaltes/ in the current template, then in the same place in the default one. And then in the system folder

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question