Disabling Image plugins for some elements

45 views Asked by At

I have html:

<div class='editable' id="a"><img src='./test.jpg'></img></div>
<div class='editable' id="b"><img src='./test1.jpg'></img></div>

I want to attach aloha editor for both divs but with image plugin for only one of them.I have tried a lot.Searched a lot.Can anyone help me?

1

There are 1 answers

0
aPokeIntheEye On

According to the guides it should be possible with this config (http://aloha-editor.org/guides/plugin_image.html)

   Aloha.settings.plugins.image: {
        config: [ 'img' ], // enable the plugin
        editables: {
            '#my-editable': [ ] // disable the plugin for the editable with ID my-editable
        }
    }

But this is broken and does not work as expected - I made bugfix and submitted a pull request at github, you can checkout my fix here: https://github.com/alohaeditor/Aloha-Editor/pull/1164