class singleton

## Methods

• ### load( scriptUrl, [ callback ], [ scope ], [ showBusy ] )CKEDITOR.scriptLoader#load

Loads one or more external scripts checking if it has not been loaded previously by this function.

CKEDITOR.scriptLoader.load( '/myscript.js' );

// HTTP error 404 should return false.
} );

alert( 'Number of failures: ' + failed.length );
} );


#### Parameters

scriptUrl : String | Array

One or more URLs pointing to the scripts to be loaded.

[ callback ] : Function

A function to be called when the script is loaded and executed. If a string is passed to scriptUrl, a Boolean parameter is passed to the callback, indicating the success of the load. If an array is passed instead, two array parameters are passed to the callback: the first contains the URLs that have been properly loaded and the second the failed ones.

[ scope ] : Object

The scope (this reference) to be used for the callback call. Defaults to CKEDITOR.

[ showBusy ] : Boolean

Changes the cursor of the document while the script is loaded.

• ### queue( scriptUrl, [ callback ] )CKEDITOR.scriptLoader#queue

since 4.1.2

Loads a script in a queue, so only one is loaded at the same time.

#### Parameters

scriptUrl : String

The URL pointing to the script to be loaded.

[ callback ] : Function

A function to be called when the script is loaded and executed. A Boolean parameter is passed to the callback, indicating the success of the load.