Php 不在Wordpress中工作的CKEditor格式插件

Php 不在Wordpress中工作的CKEditor格式插件,php,wordpress,plugins,ckeditor,Php,Wordpress,Plugins,Ckeditor,我在Wordpress网站上安装了CKEditor插件,我想为段落格式的普通div分配一个类 我试图通过向plugin文件夹添加插件来安装plugin plus所有依赖项,并添加: config.extraPlugins = 'panel,button,listblock,floatpanel,richcombo,format'; 进入CKEDITOR.config.html 我尝试将插件文件保存到wordpress/plugins的WP/WP content/plugins/ckeditor

我在Wordpress网站上安装了CKEditor插件,我想为段落格式的普通div分配一个类

我试图通过向plugin文件夹添加插件来安装plugin plus所有依赖项,并添加:

config.extraPlugins = 'panel,button,listblock,floatpanel,richcombo,format';
进入CKEDITOR.config.html

我尝试将插件文件保存到wordpress/plugins的WP/WP content/plugins/ckeditor和wordpress/ckeditor/plugins的WP/WP content/plugins/ckeditor中

然后我编辑了plugin.js格式的插件,但什么也没发生:

/**
 * The style definition to be used to apply the `'Normal (DIV)'` format. 
 *      config.format_div = { element : 'div', attributes : { 'class' : 'myClass' } };
 * @cfg {Object} [format_div={ element: 'div' }]
 * @member CKEDITOR.config
 */

CKEDITOR.config.format_div = { element : 'div', attributes : { 'class' : 'myClass' } };`
我做错了什么


我可以在没有插件的情况下为div分配一个类吗?可以在CKEDITOR.sj文件中的CKEDITOR.config.format_div={element:div}行中添加一些东西吗?

可能顺序很重要?以下几点对我很有用:

config.extraPlugins = 'panel,floatpanel,listblock,button,richcombo,format';
此外,我发现CKBuilder在某种意义上没有什么帮助,因为它没有下载我所有的插件目录。所以我不得不手动安装上面所有的插件。

你能在config.js中添加config.format\u div而不是plugin.js吗。你为什么一开始就把它放在plugin.js里?将所有配置都放在config.js中不是更好吗?