TinyMCE, iFrames, JQuery and Drupal scattered notes
Drag and drop into the TinyMCE textarea triggers onEvent twice in such close succession that it creates a race condition, and the same values for the length of the textarea before and after are given.
Getting around this by putting the character change check new value set before running the code. Maybe a timer check, or ideally a way to check the textarea with just a timer and not use onEvent at all, would be best.
I am trying very hard to make a plugin that needs to watch the text area, that is, simply run code that isn't triggered by a button. Is there a plugin that would have an example of this? Any other advice? Many thanks.
Was not a question to which I found a straightforward answer.
You can take a look at what all has been done with a
git clone http://git.agariclabs.com/git/other/tinymce-cleanword.git
Wait, replace and insert couldn't be this easy, could it?
This is the way that uses
Many of these I haven't really gone through yet. The work in this case was more about figuring out TinyMCE than
Making JQuery work within an iFrame
We didn't use this approach, doing things from within TinyMCE instead.
New jQuery Plugin - $.frameReady()
How to access iframe in jQuery
From Drupaler Nate Haug, how to access things in an iFrame with JQuery: