cross domain tinymcePopup (Result of expression 'tinymce' [undefined] is not an object.)

依然范特西╮ 提交于 2019-12-11 08:16:48

问题


I have an AIR application which has tinyMCE js into it. I have added a button on tinyMCE toolbar , upon click of which an inlinepopup window appear. this inline popup loads an url

            var aa=tinyMCE.activeEditor.windowManager.open({
            url : 'http://localhost/Save.html',
            width : 520,
            height : 340,
            resizable : "yes",
            inline : true,
            close_previous : "yes"

            });

Save.html code:

 <script src="http://www.wiris.net/demo/editor/editor"></script>
<script src="http://code.jquery.com/jquery-latest.js"></script>
<script src="../tinymce/jscripts/tiny_mce/tiny_mce_popup.js"></script>
<script>

var editor;
window.onload = function () 
{   
  editor = com.wiris.jsEditor.JsEditor.newInstance({'language': 'en'});
      editor.insertInto(document.getElementById('editorContainer'));
}

Now problem is---- When i run my AIR application i get an error
Result of expression 'tinymce' [undefined] is not an object.

I suspect a cross-domain issue because
when i alert in Save.html alert(window.document.domain); returns "localhost"

when i alert in AIR application Mxml (inside ) js alert(window.document.domain); returns " "

Thanks in advance for any suggestions & advice.

来源:https://stackoverflow.com/questions/14212705/cross-domain-tinymcepopup-result-of-expression-tinymce-undefined-is-not-an

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!