galetahub / ckeditor

Ckeditor 4.x integration gem for rails
https://ckeditor.com/ckeditor-4/
MIT License
2.23k stars 875 forks source link

Couldn't add plugin issue #897

Closed baodoan97 closed 3 years ago

baodoan97 commented 4 years ago

Hi. I see that our config.js file have included "font size and family", "justify" setting but these icon not show in the toolbar So I try to research and understand that our gem using standard package which not have these plugin Then I try to install two above plugin by following exactly document (download and put plugin and all depedencies to ckeditor/plugins) Unfortunately, I got the error resource name 'font' was not found I also searching to fix this problem but nothing can help me Does anyone know how to fix this issue?

baodoan97 commented 4 years ago

Change config.cdn_url in ckeditor to load full package ver help me no need to adding 'font' plugin. But When try to add image2 plugin I get this issue again. Can anyone help?

darko-komericki commented 4 years ago

Had the same issue here. Couldn't add extra plugins as described here.

Found out here under Enabling Local Plugins that you can define external plugin path.

e.g. Loading YouTube plugin, config.js can be written like this:

CKEDITOR.plugins.addExternal(
  "youtube",
  "/assets/ckeditor/plugins/youtube/",
  "plugin.js"
);

CKEDITOR.editorConfig = function (config) {
  config.extraPlugins = "youtube";
};
truongduyng commented 4 years ago

Had the same issue here. Couldn't add extra plugins as described here.

Found out here under Enabling Local Plugins that you can define external plugin path.

e.g. Loading YouTube plugin, config.js can be written like this:

CKEDITOR.plugins.addExternal(
  "youtube",
  "/assets/ckeditor/plugins/youtube/",
  "plugin.js"
);

CKEDITOR.editorConfig = function (config) {
  config.extraPlugins = "youtube";
};

This will not work on production env as the path will be changed after assets precompile :(

MicahBrown commented 4 years ago

Nobody has a solution to this? Seems like plugin support is pretty essential and I can't get it working with CKE 4 and rails 6. I tried the solution posted here to no avail.

I get the same error Resource name "imageresizerowandcolumn" was not found at "http://cdn.ckeditor.com/4.14.1/full/plugins/imageresizerowandcolumn/plugin.js?t=K5H9".

I followed the docs. I have the plugin located at app/assets/javascripts/ckeditor/plugins/imageresizerowandcolumn/plugin.js and config.extraPlugins = 'imageresizerowandcolumn'; in my config.js.

stale[bot] commented 3 years ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

mattgilbertnet commented 3 years ago

Had the same issue here. Couldn't add extra plugins as described here. Found out here under Enabling Local Plugins that you can define external plugin path. e.g. Loading YouTube plugin, config.js can be written like this:

CKEDITOR.plugins.addExternal(
  "youtube",
  "/assets/ckeditor/plugins/youtube/",
  "plugin.js"
);

CKEDITOR.editorConfig = function (config) {
  config.extraPlugins = "youtube";
};

This will not work on production env as the path will be changed after assets precompile :(

I was able to get this to work by using the /public folder instead of the the /app/assets folder, avoiding the assets pipeline.

thanhtoan1196 commented 3 years ago

any updates?