Early Bird Registration for DrupalCon Portland 2024 is open! Register by 23:59 PST on 31 March 2024, to get $100 off your ticket.
I'm in the process of creating a subtheme for my administration theme. As part of this process I'm using hook_theme to use a custom template for the content-type forms. WYSIWYG works find across the site but when I use hook_theme, tinymce disappears from all fields. I'm sure I'm forgetting something, but can't seem to figure this one out.
<?php
/**
* Implements hook_theme().
*/
function custom_theme_theme($existing, $type, $theme, $path) {
return array(
'custom_node_form' => array(
'render element' => 'form',
'template' => 'custom-node-form',
'path' => drupal_get_path('theme', 'custom_theme') . '/templates',
),
);
}
/**
* Preprocessor for theme('node_form').
*/
function custom_theme_preprocess_custom_node_form(&$vars) {
...
}
Comments
Comment #1
TwoDWhat do your node form template and the preprocessor function look like?
Perhaps the structure isn't understood by Wysiwyg's scripts so they can't find the format selector or the field which belongs to it.