Can anyone help me how to add a custom template to TinyMCE’s template plugin? When i tried to use the plugin, i don’t see any default template available in the templates’ dropdownlist.
Can anyone help me how to add a custom template to TinyMCE’s template plugin? When i tried to use the plugin, i don’t see any default template available in the templates’ dropdownlist.
You should use ‘template_templates’ param in ‘options’ as follow
<?php
$this->widget('application.extensions.tinymce.ETinyMce',
array(
'name'=>'Article[content]',
'options'=> array(
'theme'=>'advanced',
'skin' => 'o2k7',
'plugins' => '...,...,...,template',
'theme_advanced_buttons1' => '...',
'theme_advanced_buttons2' => '...',
'theme_advanced_buttons3' => '...',
'theme_advanced_buttons4' => '...,template,...',
'template_templates' => array(
array(
'title'=>'Editor Details',
'src'=>'editor_details.html',
'description'=>'Adds Editor Name and Staff ID'
),
...,
...,
),
'width'=>720,
),
)
); ?>