Jump to content

How to add plain text code option in IPB4?


AutoItScript
 Share

Recommended Posts

The code editor in IPB only has a drop down for HTML/PHP/CS/JS (why oh why do you never put the most useful one of plain text in there??)

From reading the docs on CKEditor and it looks like I should be able to add other supported languages you just need to add something like this to ckeditor\config.js

/*
 Copyright (c) 2003-2015, CKSource - Frederico Knabben. All rights reserved.
 For licensing, see LICENSE.md or http://ckeditor.com/license
*/
CKEDITOR.editorConfig=function(a){a.toolbarGroups=[{name:"document",groups:["mode","document","doctools"]},{name:"clipboard",groups:["clipboard","undo"]},{name$
a.removeDialogTabs="link:advanced";
a.pbckcode = {
              	modes : [ ['TEXT', 'text'], ['HTML', 'html'], ['CSS', 'css'], ['PHP', 'php'], ['JS', 'javascript'] ],
                };
};

But this doesn't seem to do anything. Is this the correct approach or has something been done in IPB4 that needs a different method?

Link to comment
Share on other sites

 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...