Hello Im trying to add a code editor, I need to let some of my users to have a code Hightlight editor, so they can choose PHP, JAVA or whatever.

This code is not going to be executed is just for exams and some other stuff

Tried to add the https://drupal.org/project/ace_editor but it has conflicts with the wysiwyg editor that comes with Commons

How ca I do this with out enter in conflicts with the actual editor. I mean is possible to asign the code highlight editor to just a certain fields?

Comments

rosemeria’s picture

Your best bet is to use a CKEditor plugin, I have been successful using other plugins for CKEditor in Drupal commons installations.

Go to CKEditor.com => Add-ons => Plugins and you will find many useful tools/plugins to add to your WYSIWYG editor.

A quick plugin search for Syntax or code Highlighting came up with "CodeMirror"

Good luck - let us know if this plugin works out.

japerry’s picture

Status: Active » Fixed

+1 to rosemeria.

You'll want to use a plugin with Ckeditor, and put it in sites/all/libraries/ckeditor/plugins

ssoulless’s picture

Ok I will try and let you know, Than you for your assistance

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.