• Word 1
  • Word 2
  • Word 3I ...">

    How to make tinymce text editor inaccessible?

    I have this html:

    <ul id="some_words"> <li>Word 1</li> <li>Word 2</li> <li>Word 3</li> </ul> 

    I said these words (word1; word2; word3) draggable as follows:

    $ ("# some_words li"). draggable ({helper: 'clone'});

    And to make the droppable , I did:

    $ ("# my-text_field"). Droppable ({accept: "#some_words li", drop: function (ev, ui) {warning ('fired'); //}});

    There is also <textarea> where TinyMCE (editor) is applied, and how this Tinymce can be droppable , as it was in the text box.

    Now, when I try to delete any word in the text box, it displays a warning window, but when you try to throw it into tinyMCE (textarea), nothing happens.

    If anyone knows how to make TinyMCE inaccessible?

    thanks

    0
    javascript jquery
    source share
    1 answer

    TinyMCE hides the text box to create an iframe next to it. So you need to get the iframe element you want to remove.

    Basically you can contact him:

     $('#my-textarea') .next('span.mceEditor') .find('iframe') .contents() .find('.mceContentBody') 

    (found with inspector on TinyMCE demo for jquery)

    Download TinyMCE first, then you can apply your droppable.

    0
    source share

    All Articles