tinyMCE is not defined

Dec 10, 2009 at 1:47 AM

I'm getting a JavaScript error "tinyMCE is not defined" on my blog.  I'm using the latest 1.5 release. 

You can see it running live @ http://devspade.com/blog

I'm not sure what the deal is as I shouldn't even be loading tinyMCE on just regular pages right??

Dec 10, 2009 at 7:11 AM

In the middle of one of your posts, you have a rogue <script> tag pointing to one of the tinyMCE JS files.  It's this post:


The HTML looks like:

Fir<script type="text/javascript" src="http://devspade.com/blog/editors/tiny_mce3/themes/advanced/langs/en.js"></script>st,

Basically, within the word "First" that <script> tag is there.  This was probably accidentally put into the post when it was being composed.

Dec 10, 2009 at 7:13 PM

Wow - of course I didn't even consider that something like that could be in there.  Thanks!!

Jan 11, 2010 at 1:26 AM

I recently installed BE 1.5 and have started creating posts. I've noticed several times that this script is inserted into my text when the post is saved:

<script type="text/javascript" src="http://toomuchgov.info/editors/tiny_mce3/themes/advanced/langs/en.js"></script>

Although I can see that TinyMCE is in the editors folder, it is not used in the post (entry) editor. That seems to be plain html. Is there a way to activate TinyMCE for this? And any idea why this script is getting dropped into my text? 

Seems like a lot of people are using Windows Live Writer...maybe I will give that a try.

Jan 12, 2010 at 5:45 PM

This is kind of strange. I installed WLW and it works great. Then the next day I happened to open the Add Event pane in the Control Panel and the Tiny MCE toolbar was displayed and seems to work fine. No idea if the two events are related or if some other change I make impacted this. 

Mar 16, 2010 at 2:45 PM

I am experiencing this issue as well. It just started doing this out of nowhere and it is screwing me all up! Is there a fix for this as I am updating pages through the browser (i.e. Safari and/or Firefox on a Mac), I don't have access to Windows Live Writer. Is there a fix for this. I am on a very tight deadline on this project and for this application to just start doing this, is just completely unacceptable!

Mar 16, 2010 at 5:56 PM

I've seen this error come up as well. I think it my case it came up when I uploaded a post from LiveWriter and then tried to edit it via the website.

Mar 16, 2010 at 6:50 PM

This appears to be an issue with tinyMCE that popped up with some recent browser versions.

Check out this thread with others reporting the same <script> tag getting inserted.  It looks like the latest version of tinyMCE has a fix for this.  You could download that, or according to the thread, you could add the following option to the tinyMCE initialization in admin\tinyMCE.ascx.

strict_loading_mode: tinymce.isWebKit

Mar 16, 2010 at 7:18 PM

Am I adding it as follows:

strict_loading_mode: "tinymce.isWebKit"

to that source file? I see yours doesn't have the quotes, which is correct? Thanks.


Mar 16, 2010 at 8:58 PM

Also, I just checked the release notes on the TinyMCE editor that gets bundled with BE 1.6 and it is version 2.1! They just released TinyMCE 3.3 just the other day. Why wouldn't at least version 3 ended up with the new BE bundle?


Mar 16, 2010 at 9:31 PM

Actually the better question is how do I go about updating the editor to the newer version? I can't seem to find any documentation on it and I think its safe to assume it's not just switching it out with the one in the "editors" folder..... or is it? hmmmm


Mar 16, 2010 at 11:05 PM

No, I don't think you need quotes.  I just took it from that thread.  tinymce.isWebKit is a JS variable that is loaded in memory, so quotation marks aren't needed.

I would first just try adding that option, without the quotation marks.

It should be pretty easy to upgrade to a newer version.  You could just overwrite the files in editors\tiny_mce3, but it might be safer to create a new folder, like tiny_mce3_1 (within the same editors folder), and unzip the new tinyMCE files into that folder.  The structure should be similar to the structure in the tiny_mce3 folder.  And then in admin\tinyMCE.ascx, it references the "tiny_mce3" folder.  So just change that to "tiny_mce_3_1" (or whatever the new folder name is).