logo

额外区块类型 (EBT) - 全新的布局构建器体验❗

额外区块类型 (EBT) - 样式化、可定制的区块类型:幻灯片、标签页、卡片、手风琴等更多类型。内置背景、DOM Box、JavaScript 插件的设置。立即体验布局构建的未来。

演示 EBT 模块 下载 EBT 模块

❗额外段落类型 (EPT) - 全新的 Paragraphs 体验

额外段落类型 (EPT) - 类似的基于 Paragraph 的模块集合。

演示 EPT 模块 滚动

滚动

在Drupal 6中创建区域

22/02/2025, by 匿名 (未验证)
论坛

您好,无法在节点中创建区域,请求您们的帮助,Drupal Jedi =) 我搜索了很多,答案都是一样的,需要添加函数 

function Имя_preprocess_node(&$vars, $hook) {

$vars['имя_региона'] = theme('blocks', 'имя_региона');
}

 

从逻辑上讲,一切应该正常工作,但服务器在添加后大声喊叫,告诉我已经有类似的函数,无法重写。它对这个函数发出警告:

 

function W_preprocess_node(&$vars) {

$vars['template_files'] = array();

$vars['template_files'][] = 'node';

 if (drupal_is_front_page()) {

 $vars['template_files'][] = 'node-front';

 }

if ($vars['page']) {

 $vars['template_files'][] = 'node-page';

 $vars['template_files'][] = 'node-'.$vars['node']->type.'-page';

 $vars['template_files'][] = 'node-'.$vars['node']->nid.'-page';

 } else {

 $vars['template_files'][] = 'node-'.$vars['node']->type;

 $vars['template_files'][] = 'node-'.$vars['node']->nid;

 if ($vars['teaser']) {

   $vars['template_files'][] = 'node-'.$vars['node']->type.'-teaser';

   $vars['template_files'][] = 'node-'.$vars['node']->nid.'-teaser';

 }

 }

}

 

该怎么办?如何才能在节点中创建区域 :)