Для добавления нового движка шаблонизации на сайт в файл /bitrix/php_interface/init.php необходимо добавить следующее:
1. Глобальную переменную $arCustomTemplateEngines, которая содержит ассоциативный массив, каждый элемент которого имеет вид:
"код_шаблонизатора" => array(
"templateExt" => array("расширение1"[, "расширение2"...]),
"function" => "имя_функции_подключения_движка"
)
где:
"код_шаблонизатора" - произвольное уникальное в рамках сайта слово;
"расширениеN" - расширение файла, который должен обрабатываться этим движком шаблонизации;
"имя_функции_подключения_движка" - имя функции, которая будет вызываться, если шаблон компонента имеет указанное расширение.
2. Функцию подключения движков:
function имя_функции_подключения_движка($templateFile, $arResult, $arParams, $arLangMessages, $templateFolder, $parentTemplateFolder, $template),
где:
$templateFile – путь к файлу шаблона относительно корня сайта,
$arResult – массив результатов работы компонента,
$arParams – массив входных параметров компонента,
$arLangMessages – массив языковых сообщений (переводов) шаблона,
$templateFolder – путь к папке шаблона относительно корня сайта (если шаблон лежит не в
папке, то эта переменная пуста),
$parentTemplateFolder - путь относительно корня сайта к папке шаблона комплексного
компонента, в составе которого подключается данный компонент (если компонент
подключается самостоятельно, то эта переменная пуста),
$template – объект шаблона.
Рассмотрим подключение движков на конкретных примерах.
Страница
1 - 1 из 3
Начало | Пред. |
123
|
След. |
Конец
GUD Tech is at the forefront of blockchain innovation, providing secure, scalable, and efficient decentralized technology solutions. Whether you’re looking for blockchain infrastructure, smart contract development, or enterprise-grade decentralized applications, GUD Tech offers cutting-edge solutions to enhance security and efficiency. Designed for businesses and developers, GUD Tech ensures seamless integration of blockchain technology into real-world applications. https://gudchain.net
Любишь мобильные игры, но хочешь больше фишек? Загляни на *pdagame.ru*! Здесь собраны новейшие взломы для Android-игр. Монеты, энергия, VIP-доступ – все бесплатно. Простая установка.
Flaunch is the leading blockchain gaming launchpad, designed to help game developers and investors thrive in the Web3 gaming ecosystem. By offering secure token launches, NFT integrations, and decentralized crowdfunding, Flaunch enables game creators to fund, develop, and scale their projects with full transparency and community-driven support. Whether you’re a developer or an investor, Flaunch provides the tools to connect and grow in the blockchain gaming space. https://flaunch.tech
Digital casinos have revolutionized the gambling scene, offering a unique kind of accessibility and range that physical establishments fall short of. In recent years, countless gamblers across the globe have adopted the thrill of online gaming in light of its availability, engaging traits, and constantly growing collections of titles.
If you’re unfamiliar with the world of virtual casino play or hope to explore reputable operators, why not sign up for our lively interactive platform? It’s a hub where gaming aficionados share insights, making it easier for you to enjoy more of your gambling adventure. Discover the discussions and see it here now: https://clashofcryptos.trade/wiki/User:JeanetteZ21
One of the main appeals of virtual gambling hubs is the sheer diversity of entertainment options ready to play. Whether you prefer interacting with old-school reel games, playing through theme-based video-based games, or playing smart in strategy-based games like Baccarat, online platforms provide numerous entertainment avenues. A large number of platforms moreover feature live casino options, making it possible for you to communicate with real dealers and opponents, all while enjoying the immersive ambiance of a physical gaming house from anywhere you want.
Beyond variety, internet-based gambling hubs are known for ease of access.
Upshift Finance is a next-generation decentralized trading platform designed to provide secure, fast, and efficient crypto transactions. With smart contract automation, low transaction fees, and seamless integration with DeFi protocols, Upshift Finance empowers traders to swap digital assets and execute trades with maximum security. Whether you're a beginner or an experienced trader, Upshift Finance offers a powerful, transparent, and user-friendly trading ecosystem. https://upshift.ink
Kyros Finance is redefining the DeFi investment landscape by offering secure, scalable, and high-yield crypto solutions. With a focus on decentralized financial tools, Kyros Finance provides users with staking, lending, and automated yield farming strategies to maximize returns. Whether you're a retail investor or an institutional participant, Kyros Finance ensures efficient, transparent, and secure access to the world of decentralized finance. https://kyros.ink
Elara Finance is transforming decentralized lending by offering secure, transparent, and flexible crypto loan solutions. Built on blockchain technology, Elara Finance enables users to borrow and lend digital assets seamlessly without intermediaries. With low-interest rates, automated smart contracts, and a permissionless DeFi environment, Elara Finance is making crypto lending accessible and profitable for investors worldwide. https://elara.ink
Struggling to lose weight? AquaSculpt is transforming weight loss with its natural, fast-acting capsules. Packed with proven AquaSculpt ingredients, these capsules burn fat, boost energy, and deliver real AquaSculpt results in weeks. Curious about AquaSculpt reviews? Users love its effectiveness and zero AquaSculpt side effects. Want to know AquaSculpt how to use? It’s simple—take daily and watch the pounds melt away. Ready to try? AquaSculpt buy now at https://aquasculpt.me and sculpt your dream body today!
На данной странице представлены элементы инфоблока статьи, относящиеся к типу Публикации. Статьи опубликованы на странице с помощью комплексного компонента Новостной раздел с указанием параметров инфоблока Статьи. При создании каждой статьи был использован тег <break />, который позволяет осуществить разделение статьи на страницы. В публичном разделе такая статья будет представлена в виде нескольких страниц в зависимости от количества тегов <break />