﻿id	summary	reporter	owner	description	type	status	priority	milestone	component	version	resolution	keywords	cc
4160	"Firefox WinXP 3.5.1: Seeing ""Your browser is not compatible with CKEditor"" error"	blumunky		"I'm using Firefox 3.5.1 on Windows XP Pro SP2

I'm seeing the ""Your browser is not compatible with CKEditor..."" error when I visit any of the [http://ckeditor.com/ckeditor/3.0rc/_samples/index.html RC3 demos] or the nightly [http://nightly.ckeditor.com/4016/_samples/ 4016 demos]

However, all of the fckeditor [http://www.fckeditor.net/demo v2 demos] work

After some digging, it appears that the problem might be that my browser is reporting a browser agent of:

""Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:'''1.8.0.2''') Gecko/20060308 Firefox/1.5.0.2""

In env.js, the following line 135:
{{{
version = geckoRelease[0] * 10000 + ( geckoRelease[1] || 0 ) * 100 + ( geckoRelease[2] || 0 ) * 1;
}}}

Converts this rv string into a gecko version of 10800 which at line 178:
{{{
env.isCompatible =
  ( env.ie && version >= 6 ) ||
  ( env.gecko && version >= 10801 ) ||
  ( env.opera && version >= 9.5 ) ||
  ( env.air && version >= 1 ) ||
  ( env.webkit && version >= 522 ) ||
  false; 
}}}

Causes isCompatible to become false;

This issue is that the code is assuming that the first digit in the rv is the 10000s place.  I certainly don't know why this decision was made or whether or not my proposed change will break something else, but here goes:

I propose that in env.js, line 135 be changed to:
{{{
for(var mult=1,ii=geckoRelease.length-1;ii>=0;ii--,mult*=10) {
  version += (mult * geckoRelease[ii]);
}
}}}

This will convert an rv of 1.8.0.2 into a gecko version of 1802.  This of course means that all instances where a gecko version of 10xxx is expected will need to be changed.  I changed the following instances:

'''env.js line 185''':
{{{
( env.gecko && version >= 10801 ) ||
}}}

became
{{{
( env.gecko && version >= 1801 ) ||
}}}

'''editor.js line 141'''
{{{
if ( CKEDITOR.env.gecko && CKEDITOR.env.version < 10900 && editor.lang.dir == 'rtl' )
}}}

became
{{{
if ( CKEDITOR.env.gecko && CKEDITOR.env.version < 1900 && editor.lang.dir == 'rtl' )
}}}

'''plugins\button\plugin.js line 238, plugins\plugin.js line 562,  and plugins\elementspath\plugin.js line 95'''
{{{
if ( CKEDITOR.env.gecko && CKEDITOR.env.version < 10900 )
}}}

became
{{{
if ( CKEDITOR.env.gecko && CKEDITOR.env.version < 1900 )
}}}

Making these changes fixed the problem for me."	Bug	closed	Normal		General	3.0 RC	invalid	WorksForMe	
