﻿id	summary	reporter	owner	description	type	status	priority	milestone	component	version	resolution	keywords	cc
5952	window.CKEDITOR_BASEPATH ignored	Maciej Wiercinski		"I'm using PHP5 object to generate CKEditor instances. The resulting HTML is: 

{{{
<script type=""text/javascript"">//<![CDATA[
window.CKEDITOR_BASEPATH='http://<url>/plugins/ckeditor/';
//]]></script>
<script type=""text/javascript"" src=""http://<url>/plugins/ckeditor/ckeditor.js?t=A1QD""></script>
}}}

Not sure why's that a case, but in some circumstances window.CKEDITOR_BASEPATH is not visible from scope of the ckeditor.js (verified by alerting that variable, comes as undefined). 

We've got around it by declaring it twice: 

{{{
$ svn diff ckeditor_php5.php 
Index: ckeditor_php5.php
===================================================================
--- ckeditor_php5.php	(revision 14361)
+++ ckeditor_php5.php	(working copy)
@@ -454,7 +454,7 @@
 
 		// Skip relative paths...
 		if (strpos($ckeditorPath, '..') !== 0) {
-			$out .= $this->script(""window.CKEDITOR_BASEPATH='"". $ckeditorPath .""';"");
+			$out .= $this->script(""window.CKEDITOR_BASEPATH='"". $ckeditorPath .""';var CKEDITOR_BASEPATH='"". $ckeditorPath .""';"");
 		}
 
 		$out .= ""<script type=\""text/javascript\"" src=\"""" . $ckeditorPath . 'ckeditor.js' . $args . ""\""></script>\n"";
}}}

At least one affected browser: 

Mozilla/5.0 (X11; U; Linux i686; en-GB; rv:1.9.1) Gecko/20090624 Firefox/3.5
"	Bug	closed	Normal		General	3.3.1	invalid		
