0
사용자 지정 콘텐츠 형식이라는 콘텐츠 형식을 만들었습니다. 콘텐츠 형식을 id.I 형식으로 재정의하려면 template.php와 custom-content-type-node-form에 bartik_theme을 포함 시켰습니다. 내 양식 ID와 내가 바틱의 템플릿에 사용자 정의 콘텐츠 유형 노드 form.tpl.php를 만들었습니다.하지만 override.Iut 수 없습니다. 또한 dpm() 함수를 사용하여 노력하지 않는 배열 구조를 인쇄하려고합니다. 감사합니다 당신은 사전에 ...콘텐츠 형식이 drupal7에서 재정의되지 않습니다.
I included this in template.php
function bartik_theme() {
return array(
'custom_content_type_node_form' => array(
'arguments' => array('form' => NULL),
'template' => 'templates/custom-content-type-node-form',
'render element' => 'form'
),
);
}
I created custom-content-type-node-form.tpl.php in template folder
<?php
dpm($form);
hide($form['body']);
print drupal_render_children($form['field_custom_image']);
print drupal_render_children($form['title']);
print drupal_render_children($form);
?>
drupal 제안을 살펴보십시오. hook_theme을 모두 구현하지 않아도됩니다. https://drupal.org/node/1089656 –