Login
No account yet? Register
Home arrow Twiners Codex
Twiners Codex
Code snippets, design patterns, and more!

TinyMCE Error PDF Print E-mail
Written by Eric Avary   
Monday, 27 August 2007

For those of you using TinyMCE in your Joomla install, you may find that there's an error that occurs when you're trying to create a link or add an image.  Basically, the issue presents itself when TinyMCE needs to load a popup window, and it manifests itself by showing a blank window and issuing the following error:

  uncaught exception: Permission denied to get property Window.tinyMCE

 ...followed by a couple of complaints stating:

  tinyMCE has no properties

This problem is caused by the TinyMCE javascript files residing in a different domain or subdomain than the admin site.  If you want to know why it occurs, Mozilla discusses it under the topic, Same Origin Policy.  Their fix is to enter:

 document.domain = "domain.com";

... which would be implemented by editing the tiny_mce_popup.js file (inside the TinyMCE folder) and adding the line at the top of the init block -- so that it's the first line inside init.

In the case of our Joomla install, this did not work and we ended up with a different error... because the issue had to do with the live site variable inside configuration.php.  We recommend, therefore, not editing tiny_mce_popup.js, but rather editing your configuration.php file to show 'www' in your $mosConfig_live_site variable.  Like so:

  $mosConfig_live_site = 'http://www.yoursite.com';

It worked for us, and we hope that it works for you!

 

Last Updated ( Monday, 27 August 2007 )
 
The Twiners Codex PDF Print E-mail
Written by Arthur Avary   
Thursday, 19 July 2007
Welcome to the Twinerss web codex... a place to share our thoughts and code snippets... Things we wish we might have found online when we were between a rock and a hard place in our development efforts.
Last Updated ( Thursday, 23 August 2007 )