0
我需要自定義Symfony包IvoryCKEditorBundle的工具欄的項目。IvoryCKEditorBundle:如何自定義工具欄項目?
我知道可以通過在this way中添加項目來定製工具欄,但是如何編輯項目本身或創建自定義項目?
CKEditor文檔解釋它here,但我不確定如何使用Symfony IvoryCKEditor軟件包來做同樣的事情。
我需要自定義Symfony包IvoryCKEditorBundle的工具欄的項目。IvoryCKEditorBundle:如何自定義工具欄項目?
我知道可以通過在this way中添加項目來定製工具欄,但是如何編輯項目本身或創建自定義項目?
CKEditor文檔解釋它here,但我不確定如何使用Symfony IvoryCKEditor軟件包來做同樣的事情。
一種優雅的方式可以是由第一creating a CKEditor plugin,然後loading the plugin into the IvoryCKEditorBundle:
# app/config/config.yml
ivory_ck_editor:
default_config: my_config
configs:
my_config:
extraPlugins: "mycustomplugin"
plugins:
mycustomplugin:
path: "/bundles/mybundle/mycustomplugin/"
filename: "plugin.js"
插件文件夾(在我的例子mycustomplugin
)應束源(例如src/MyBundleName/Resources/pubic
)的Resources/public
文件夾下被放置。
編輯:此外,要知道,如果你需要安裝多個插件,該extraPlugins列表應該用逗號沒有空間隔開,如:
extraPlugins: "mycustomplugin1,mycustomplugin2,mycustomplugin3"