26

Re: TinyMCE 3.2.1 Released

I'm afraid I wasn't clear again.  I did try using the editor_selector and changing the mode, and removing the execCommand(), and it did the same thing, so I figured that wasn't the fix I needed, and started trying to debug it the way it was before.

I'm pretty sure I finally figured out the problem!  IE6 has various issues with gzip, like this one which causes pages not to load correctly when you have:
    * Script in external files, for example, JScript (.js) files
    * Frames and script inside the frames that refers to variables or to methods that are defined in other frames
    * HTTP compression to compress the HTML and the script files
    * HTTP headers that prevent the browser from caching the pages

The calendar popup we used was having issues at one point where select boxes would show through the div because of another IE6 bug, so on IE6 we create an additional iframe to put under it.  I think this completed the requirements necessary to produce this bug. 

So basically Internet Explorer wasn't reading and unpacking the gzipped javascript correctly sometimes. As the KB article says, "The symptoms of this problem typically occur inconsistently and may appear random."  That behavior led me to believe there was some kind of timing error, which probably wasn't the case.

So I'm going to try the following when initializing the gzip loader:

    var isIE6 = /msie|MSIE 6/.test(navigator.userAgent); 

    tinyMCE_GZ.init({ 
            plugins : tnlTinyMcePluginList, 
            themes : 'advanced',
            compress : !(isIE6), //IE6 isn't reliable with gzip.
            languages : 'en' 
    });

That way, I can still take advantage of the gzip loader to pack everything into one request, but it won't use gzip on IE6.  As soon as I get a chance to test it, I'll let you know how it works out.

PS -- is there any reason that the bug fix mentioned here was never applied to the compressor JSP?  All you have to do is remove a carriage return.

Last edited by j2jensen (2008-11-24 20:57:00)

27

Re: TinyMCE 3.2.1 Released

We have a workaround for this issue. By loading the scripts over a XHR call. It worked fine when I tested it on a "broken" IE installation.

Best regards,
Spocke - Main developer of TinyMCE

28

Re: TinyMCE 3.2.1 Released

Spocke, could you please look at the Example Skins page and confirm for me that the silver and black variants show the wrong colours on the selection arrow next to (for example) the color picker? smile
I think something in the blue skin has changed (says my SVN) which hasn't been merged into the black and silver variants.

I saw in ui_black.css and ui_silver.css that there is still a reference to span.mceOpen which has changed to a.mceOpen since v3.2.1. After replacing span.mceOpen with a.mceOpen in both files, the arrows will show the right background.

Last edited by MeAngry (2008-11-25 14:45:26)

29

Re: TinyMCE 3.2.1 Released

Yes, I think this is related to the IE 8 bug fixes.

Best regards,
Spocke - Main developer of TinyMCE

30

Re: TinyMCE 3.2.1 Released

It turns out I was wrong about gzip being the problem.  After doing enough testing, I came to realize that even using the tiny_mce.js loader, the problem still appeared every now and then.  So I kept playing around with it enough to realize that our calendar popup javascript seemed to be the only factor with a consistent impact.  I began commenting out lines in that file until I narrowed it down to one line of code, which looked like this:

        document.getElementById('dateSelector').innerHTML=str;

Apparently updating an element via innerHTML caused some kind of problem.  Maybe this method returned before the DOM was finished updating, and so TinyMCE would sometimes try to access the DOM while it was in a weird state.  I don't really know.  But changing the above code to this seems to have fixed it:

        var oldDiv = document.getElementById('dateSelector');
        var newDiv = oldDiv.cloneNode(false);
        newDiv.innerHTML = str;
        oldDiv.parentNode.replaceChild(newDiv,oldDiv);

31

Re: TinyMCE 3.2.1 Released

Nice to hear that is was sorted out.

Best regards,
Spocke - Main developer of TinyMCE