I have both this module and latest TinyMCE editor installed and appear to run properly but not sure why some of the buttons are not available in Wysiwyg profile settings. I notice at least spellchecker and template plugins are not available. Is it by design to disable the use of some plugins?

See screen snapshot of available buttons in my profile setting. Almost all buttons are there, just a few and it happens I need the "template" button the most and it is not there.

CommentFileSizeAuthor
wysiwyg_missing_buttons.gif56.01 KBarnoldc
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

sun’s picture

Status: Active » Closed (works as designed)

Some plugins are not yet available due to #328252: Handle compatibility of internal plugins via plugin API.

Some others are not supported, currently by design. I don't know what this "template" plugin does or is for, but maybe I left it out on purpose, too.

arnoldc’s picture

Template plugin is an important function as it allows one to insert pre-defined HTML templates or snippets to the content. If people need WYSIWYG editor, chance is they also want this function. This can very well be a deal breaker in choosing an editor.

Anyway, I manage to enable this function by following the given thread. You may consider to incorporate it in future release.

In my example, I store the template list in /sites/template_list.js but it can be placed anywhere else.

1. In tinymce.inc file:

Add the following entry to the $init array in the function wysiwyg_tinymce_settings():
'template_external_list_url' => base_path().'sites/template_list.js',

Add the following entry to $plugins array in the function wysiwyg_tinymce_plugins():

    'template' => array(
      'path' => $editor['library path'] .'/plugins/template',
      'buttons' => array('template' => t('Insert templates')),
      'url' => 'http://wiki.moxiecode.com/index.php/TinyMCE:Plugins/template',
      'internal' => TRUE,
      'load' => TRUE,
    ), 

2. My sample /sites/template_list.js file:

// This list may be created by a server logic page PHP/ASP/ASPX/JSP in some backend system.
// There templates will be displayed as a dropdown in all media dialog if the "template_external_list_url"
// option is defined in TinyMCE init.

var tinyMCETemplateList = [
	// Name, URL, Description
	["Page: 1", "sites/tinymce_templates/page1.htm", "Page One layout."],	
	["Page: 2", "sites/tinymce_templates/page2.htm", "Page Two layout."]
];

3. Create your own page1.htm and page2.htm accordingly.

4. Enable the button in your wysiwyg profile. Done!

sun’s picture

I see. This is something a Drupal module can provide as a so-called "Drupal plugin", globally, for all editors (that support Drupal plugins). Which means, the module can provide a complete administrative UI, integration with other modules, etc. pp

jenlampton’s picture

Category: bug » support
Status: Closed (works as designed) » Active

Is there any documentation on how to write a "drupal plugin"? I'd prefer to get this functionality working with FCK editor.
Jen

jenlampton’s picture

Title: Some plugins are missing in profile setting using TinyMCE editor » TinyMCE editor plugin 'Template' as a 'Drupal plugin' instead?
Version: 6.x-1.1 » 6.x-2.x-dev
Component: Editor - TinyMCE » Plugins

voila http://drupal.org/project/wysiwyg_template

I'm starting with this plugin for TinyMCE, I'd love some feedback :-)

sun’s picture

Status: Active » Closed (fixed)