문제

Do anyone here know how to add custom BBCode tags to CKEditor 4? I have tried to look at ckeditor.js, but I can't seem to find the right part to edit.

Actually, I just have to change the align buttons to output [left], [right] and [center] tags instead of:

<div style="text-align: left">{TEXT_HERE}</div>

I have already tried to find it on Google, but everything I found was for older versions of CKEditor and/or the BBCode plugin.

Any help is appreciated!

도움이 되었습니까?

해결책

I assume you want to edit this plugin: http://ckeditor.com/addon/bbcode

You just simply need to the 'div' tag to bbcodeMap and tagnameMap to be converted (and not rewritten to p tag). Another stap is to edit stylesMap by adding align: 'text-align'.

That shoudl work.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top