68
if ( FCKBrowserInfo.IsSafari )
68
FCKScriptLoader.LoadFile = function( filePath )
70
FCKScriptLoader.LoadFile = function( filePath )
72
if ( filePath.lastIndexOf( '.css' ) > 0 )
78
var oXmlRequest = new XMLHttpRequest() ;
80
// Load the script synchronously.
81
oXmlRequest.open( "GET", filePath, false ) ;
82
oXmlRequest.send( null ) ;
84
// Evaluate the script.
85
if ( oXmlRequest.status == 200 )
89
eval( oXmlRequest.responseText ) ;
93
alert( 'Error parsing ' + filePath + ': ' + e.message ) ;
70
//window.status = ( 'Loading ' + filePath + '...' ) ;
72
// Dynamically load the file (it can be a CSS or a JS)
76
if ( filePath.lastIndexOf( '.css' ) > 0 )
78
e = document.createElement( 'LINK' ) ;
79
e.rel = 'stylesheet' ;
85
e = document.createElement( "script" ) ;
86
e.type = "text/javascript" ;
89
// Add the new object to the HEAD.
90
document.getElementsByTagName("head")[0].appendChild( e ) ;
92
// Start downloading it.
93
if ( e.tagName == 'LINK' )
95
// IE must wait for the file to be downloaded.
96
if ( FCKBrowserInfo.IsIE )
97
e.onload = FCKScriptLoader_OnLoad ;
98
// Gecko doens't fire any event when the CSS is loaded, so we
97
alert( 'Error loading ' + filePath ) ;
101
FCKScriptLoader.CheckQueue() ;
107
// Gecko fires the "onload" event and IE fires "onreadystatechange"
108
e.onload = e.onreadystatechange = FCKScriptLoader_OnLoad ;
113
function FCKScriptLoader_OnLoad()
104
FCKScriptLoader.LoadFile = function( filePath )
106
//window.status = ( 'Loading ' + filePath + '...' ) ;
108
// Dynamically load the file (it can be a CSS or a JS)
112
if ( filePath.lastIndexOf( '.css' ) > 0 )
114
e = document.createElement( 'LINK' ) ;
115
e.rel = 'stylesheet' ;
116
e.type = 'text/css' ;
121
e = document.createElement( "script" ) ;
122
e.type = "text/javascript" ;
125
// Add the new object to the HEAD.
126
document.getElementsByTagName("head")[0].appendChild( e ) ;
128
// Start downloading it.
129
if ( e.tagName == 'LINK' )
131
// IE must wait for the file to be downloaded.
132
if ( FCKBrowserInfo.IsIE )
133
e.onload = FCKScriptLoader_OnLoad ;
134
// Gecko doens't fire any event when the CSS is loaded, so we
135
// can't wait for it.
137
FCKScriptLoader.CheckQueue() ;
143
// Gecko fires the "onload" event and IE fires "onreadystatechange"
144
e.onload = e.onreadystatechange = FCKScriptLoader_OnLoad ;
149
function FCKScriptLoader_OnLoad()
151
// Gecko doesn't have a "readyState" property
152
if ( this.tagName == 'LINK' || !this.readyState || this.readyState == 'loaded' )
153
// Load the next script available in the queue
154
FCKScriptLoader.CheckQueue() ;
115
// Gecko doesn't have a "readyState" property
116
if ( this.tagName == 'LINK' || !this.readyState || this.readyState == 'loaded' )
117
// Load the next script available in the queue
118
FCKScriptLoader.CheckQueue() ;
b'\\ No newline at end of file'