FCKeditor breaks with Firefox 3.5.8

UPDATE: FCKEditor 2.6.6 released and fixes this problem.  http://ckeditor.com/blog/FCKeditor_2.6.6_released


My FCKeditor 2.6.3 STANDALONE install suddenly stopped working today.  My informants tell me this DOES NOT affect CFTEXTAREA set to RichText.

I tracked down the problem to the fckutils.cfm file  FCKeditor tests for browser compatibility and displays a regular textarea if the browser tests "false". 

Why is Firefox 3.5.8 not compatible?  The code below reFind("gecko/200 ...) does not work because the new firefox is gecko/20100202

stResult = reFind( "gecko/(200[3-9][0-1][0-9][0-3][0-9])", sAgent, 1, true );

I added a second if statement

stResult = reFind( "gecko/(201[0-9][0-9][0-9][0-9][0-9])", sAgent, 1, true );

Here is the fix in context of the fckutils.cfm

// check for Gecko ( >= 20030210+ )
else if( find( "gecko/", sAgent ) )
{
   // try to extract Gecko version date
   stResult = reFind( "gecko/(200[3-9][0-1][0-9][0-3][0-9])", sAgent, 1, true );
       
// START TO TEST FOR FIREFOX 3.5.8 and higher
if ( arrayLen( stResult.pos ) eq 1 ) {
        stResult = reFind( "gecko/(201[0-9][0-9][0-9][0-9][0-9])", sAgent, 1, true );
   }
// END TO TEST FOR FIREFOX 3.5.8 and higher
       
if( arrayLen( stResult.pos ) eq 2 )
  {
    // get Gecko build (i18n date)
        sBrowserVersion = mid( sAgent, stResult.pos[2], stResult.len[2] );
       if( sBrowserVersion GTE 20030210 )
            isCompatibleBrowser = true;
    }
}

Worked like a charm.  Happy coding...

3 responses to “FCKeditor breaks with Firefox 3.5.8 ”

  1. Andrew Myers Feb 21, 2010 at 1:56 PM
    Thanks! Very helpful info.
  2. Ethan Feb 22, 2010 at 11:11 AM
    Thank you - this really helped.
  3. bil_ Mar 2, 2010 at 11:26 PM
    Awesome! Thanks for posting both the fix and the update. Sweet title too...exact phrase I searched for...first result==solution!

Leave a Reply

Leave this field empty:

Powered by Mango Blog.