I am using CkEeditor to edit the node body field. I want to add a Select template option in CkEditor.


1 Answer 1


I suggest you have a closer look at the widget API / the widget plugin for CKEditor. The widget API enables you to have something like 'templates' meaning predefined groups of elements inside the editor window.

"Widgets are special rich content units in that they are groups of elements which are treated as a single entity inside the editor."


At the end of that page there are links to further info about the Widget SDK and a step-by-step tutorial for creating your own widget ('mini-template').

I use the widgets plugin myself together with the SCALD module family and I must say I am still quite excited how very well these two play together.

If you 'just' want to add content templates however, you should probably download and install the Content Templates plugin for CKEditor.

From the download dialog window:

Extract the downloaded plugin .zip into the plugins folder of your CKEditor installation. Example:


Enable the plugin by using the extraPlugins configuration setting. Example:

config.extraPlugins = 'templates';

Download and configure all its dependencies, too.

Add-on Dependencies: Dialog

The configuration setting can be found/added in config.js inside the ckeditor directory.

  • awesomescreenshot.com/0404r4oxe2 PLease check this. I need this.
    – jsh
    Commented Mar 30, 2015 at 9:23
  • oky, you'll probably want the Content Templates plugin for CKEditor. I edited my answer accordingly. Commented Mar 30, 2015 at 9:29
  • I have download and put it sites\all\modules\ckeditor\plugins\templates.. but it not showing on editor.awesomescreenshot.com/00f4r4wc62
    – jsh
    Commented Mar 30, 2015 at 9:37
  • where I need to use this code: config.extraPlugins = 'templates';
    – jsh
    Commented Mar 30, 2015 at 9:57
  • I fear this is getting beyond 'drupal' – but anyways: have you read and folloewd the install info? There are at least two addinitional steps necessary – I pasted them above.. Commented Mar 30, 2015 at 9:57

Not the answer you're looking for? Browse other questions tagged or ask your own question.