christiaan / tinymce-codemirror

Development moved to gitlab.com/tinymce-plugins/tinymce-codemirror
https://gitlab.com/tinymce-plugins/tinymce-codemirror
Apache License 2.0
71 stars 29 forks source link

Problem with CrossDomain iFrame #3

Closed simnzz closed 5 years ago

simnzz commented 8 years ago

I've got a problem with an CrossDomain installation of tinyMCE with the codemirror-plugin enabled.

The source.html cannot be loaded over two different domains (all other plugins doesn't have this issue), it failes with:

Uncaught SecurityError: Blocked a frame with origin "http://TINYMCE_HOSTING_DOMAIN" from accessing a frame with origin "http://CUSTOMER_DOMAIN". Protocols, domains, and ports must match.

Any idea? Can't get it working so far with document.domain = document.domain or other mechanism...

thomich commented 8 years ago

Hello @simnzz

To know, if this still exists: Can you reproduce your reported issue also with latest TinyMCE and tinymce-codemirror code?

Thanks for your reply

Regards thomi

thomich commented 8 years ago

Hey @simnzz

If you had time to test, we are interested in your result.. else we will close this issue.

Thanks in advance thomi

thomich commented 7 years ago

Hey @simnzz

Would be nice, if you give us some feedback...

Many thanks

Regards thomi

frankliang610 commented 5 years ago

Hi @thomich, Hope you are still maintaining this project.

I've got the same issue when using Chrome to open the HTML source code page. It says: "Uncaught DOMException: Blocked a frame with origin "null" from accessing a cross-origin frame." The error was caught in source.html (tinymce = parent.tinymce). A screenshot will be attached to show it. Blocked a frame with origin issue

I tried to google and fix it but couldn't find any solutions. Hope you could help me with this issue. Thank you very much.

Here are the detialed info about the versions I am dealing with. TinyMCE V4.9.4 with CodeMirror V5.45.0, working on Chrome V73.0.3683.103(Official Build 64bit) Firefox V66.0.3 (64-bit) and IE 11 are working well without any problem, though IE needs to click the javascript activate button manually every time.

Thank you again. Kind regards, frank

thomich commented 5 years ago

Hey @frankliang610

Yes i'm still in ;) but the time.... Will try to repoduce the issue and give feedback, but i need time, as lot's of other projects are pending.

Regards thomi

frankliang610 commented 5 years ago

Hi @thomich

Thank you for your reply. Yes, I understand it and I am very appreciated that you will spare your time to take a look at the issue.

Thank you again. (^ ^)

Kind regards, frank

thomich commented 5 years ago

Please check: https://github.com/christiaan/tinymce-codemirror/issues/46

Daijobou commented 5 years ago

@simnzz @frankliang610 @thomich In file source.html you must add on top document.domain = 'your-domain.tld'; Here should codemirror plugin have a setting, so I can set domain-value via tinymce-codemirror settings.

thomich commented 5 years ago

please check our new repo

https://gitlab.com/tinymce-plugins/tinymce-codemirror

report a issue ther or even better, create a merge request 😊👍