0

次のように指定しようとすると、 forCKEditorとして使用しようとしています。WidgetVignettecontent css outside the environment of CKEditor

"CKEDITOR.config.contentsCss = 'http://lvhost:27110/CKEditorbk/my.css';" 

動作しませんが、次のような ckeditor の展開がある戦争に含まれるコンテンツ css を指定すると:

CKEDITOR.config.contentsCss = 'http://lvhost:27110/CKEditor/ckeditor/my.css'; 

期待どおりに機能しています。Isn't possible to specify a css outside "CKEditor.basepath"?

4

1 に答える 1

1

実際、CKEditor パス スコープは という名前のフォルダー内にあるため、できませんckeditor

ただし、同じフォルダー構造、つまり/js/CUSTOM_CKEDITOR/ckeditor. CKeditor のプラグインを作成したときにそうしました。

にカスタム CSS があり/js/CUSTOM_CKEDITOR/ckeditor/plugins/my_plugin/css/custom.cssます。そして、私/js/CUSTOM_CKEDITOR/ckeditor/config.jsは使用しました:

CKEDITOR.config.contentsCss = CKEDITOR.plugins.getPath( 'my_plugin' ) + 'css/custom.css';

甘い作品:)

于 2012-03-19T02:15:40.560 に答える