How would one insert content into tinyMCE?
-
*Skip this paragraph if you just want to read my question
Basically, I am writing a shortcode where when you click on the icon in tinyMCE, it brings up a custom dialog box that asks for a URL. It sends that URL to another PHP page which dissects the page to figure out how it can display the content (be it a custom video player specific to that site, an img, etc) and then returns those variables.What I would like to do is at the caret position in tinyMCE, insert this result (ex, [media id=”Something” url=”www.example.com”]). I found tinyMCE.execCommand(mceInsertContent etc. but I can’t figure out how to execute it correctly…
The topic ‘How would one insert content into tinyMCE?’ is closed to new replies.