In Drupal 6, there was a method to theme the edit form for nodes of a custom type:
/**
* Implements hook_theme().
*/
function hook_theme($existing, $type, $theme, $path) {
return array(
'node-type_node_form' => array(
'variables' => array(
'form' => NULL,
),
'template' => 'node_type-node-form',
),
);
}
Drupal 7 handles this method with the following template files: page--node--add--contenttype.tpl.php, or, page--node--edit--contenttype.tpl.php.
I didn't find any documentation about how I should render form items in these templates. $form
is null.
Which variable should I use to render the edit form for my content type?