Html 5 Video Plugin for CKEditor 4.1.1

There was an HTML 5 plugin for ckedior here http://ckeditor.com/forums/Plugins/HTML5-Video

but unfortunately the Video plugin does not work correctly on CKEditor 4.1.1

It works until you see the source, if you click on the source and return to the editor, write "Your browser does not support video ....

Could you guide me?

+4
source share
3 answers

Just the same problem. This seems to be because in CKEditor 4.1 they added an additional content filter. And in fact, if the plugin does not explicitly say that some tags like <video></video> allowed, they will simply be deleted by the source editor !!! My workaround was to disable ACF in the editor by adding the following line at the beginning of the ckeditor / config.js file:

 CKEDITOR.config.allowedContent = true; 

Thus, the source code editor no longer checks the contents of html, so it accepts everything! As a result, the <video>...</video> no longer deleted!

Interception helps

Greetings -Christian

+4
source

Instead of completely disabling content filtering in your ckedito, you can simply specify

 extraAllowedContent: 'video[*]{*}' 

in the config.js file.

+15
source

after loading the plugin, extract it to ckeditor / plugin then go to ckeditor.js and find "CKEDITOR.config.plugins =" ​​and then add ", video" at the end of it

for example: 'Dialogui, dialogue, about, video' CKEDITOR.config.plugins =; then the plugin works correctly.

0
source

Source: https://habr.com/ru/post/1481620/


All Articles