Now that the CKEditor is finally ready (#462146: Add editor: CKeditor)...

Comments

whatdoesitwant’s picture

Subscribing.

jaxpax’s picture

+1

momper’s picture

what about the standalone version of ckeditor?

s4j4n’s picture

+1

sinasalek’s picture

CKEdtior is getting more popular everyday specially among Drupalers. that would nice to have this feature.

thanks

sinasalek’s picture

sinasalek’s picture

Here is my first effort! the button appears on wysiwyg config however is receive the following error. couldn't figure how how to fix it yet.

The resource name syntaxhighlight is already registered
<?php
/**
* Implementation of hook_wysiwyg_plugin().
*/
function wysiwyg_syntaxhl_wysiwyg_plugin($editor) {
 ...
    case 'ckeditor':
      if (!isset($integrated)) {
        $integrated = TRUE;
        $languages=array();
        foreach ( variable_get('syntaxhighlighter_enabled_languages', array('shBrushPhp.js')) as $ind=>$val) {
          if ($val) {
            $languages[]=array('value' => strtolower(substr(substr($ind, 7),0,-3)), 
              'text' => substr(substr($val, 7),0,-3)
            );            
          }
        }
        $settings = array(
          'wysiwyg_syntaxhl' =>  array('languages' => $languages)
        );
      drupal_add_js($settings, 'setting');
    }
    $path = drupal_get_path('module', 'wysiwyg_syntaxhl') . '/ckeditor/syntaxhighlight/plugin.js';
    return array(
        'syntaxhighlight' => array(
          'path' => $path,
          'buttons' => array('Code' => t('SyntaxHighlighter')),
          'url' => 'http://code.google.com/p/ckeditor-syntaxhighlight/',
          'load' => TRUE,
        ),
    );
  }
}
?>
meecect’s picture

I'll add it to my todo list.

mausolos’s picture

I haven't found anything on the web showing how to make the Google Code js solution (mentioned in #8) actually work with the WYSIWYG module. There appear to only be solutions for getting it to work with the CKEditor module. I may try my hand at it, just out of sheer frustration and stubbornness, but it would be really great to see support for this. I haven't been with an organization, or personally known anyone else whose been at an organization that has used TinyMCE since 2007 - everyone seems to be using CKEditor these days! :)