# CKEditor 3.0 JavaScript API Documentation

Code Index | File Index

## Namespaces

- CKEDITOR
- CKEDITOR.ajax
- CKEDITOR.config
- CKEDITOR.dom
- CKEDITOR.dtd
- CKEDITOR.env
- CKEDITOR.imageCacher
- CKEDITOR.loader
- CKEDITOR.plugins
- CKEDITOR.resourceManager
- CKEDITOR.scriptLoader
- CKEDITOR.skins
- CKEDITOR.test
- CKEDITOR.themes
- CKEDITOR.tools

## Classes

- CKEDITOR.commandDefinition
- CKEDITOR.dialog
- CKEDITOR.dialog.buttonDefinition
- CKEDITOR.dialog.contentDefinition
- CKEDITOR.dialog.contentDefinitionObject
- CKEDITOR.dialog.dialogDefinition
- CKEDITOR.dialog.dialogDefinitionObject
- CKEDITOR.dialog.uiElementDefinition
- CKEDITOR.dialogCommand
- CKEDITOR.dom.document
- CKEDITOR.dom.domObject
- CKEDITOR.dom.element
- CKEDITOR.dom.event
- CKEDITOR.dom.node
- CKEDITOR.dom.selection
- CKEDITOR.dom.text
- CKEDITOR.dom.window
- CKEDITOR.editor
- CKEDITOR.event
- CKEDITOR.eventInfo
- CKEDITOR.focusManager
- CKEDITOR.htmlParser
- CKEDITOR.htmlParser.cdata
- CKEDITOR.htmlParser.comment
- CKEDITOR.htmlParser.element
- CKEDITOR.htmlParser.fragment
- CKEDITOR.htmlParser.text
- CKEDITOR.htmlWriter
- CKEDITOR.keystrokeHandler
- CKEDITOR.pluginDefinition
- CKEDITOR.ui
- CKEDITOR.ui.button
- CKEDITOR.ui.dialog.button
- CKEDITOR.ui.dialog.checkbox
- CKEDITOR.ui.dialog.file
- CKEDITOR.ui.dialog.fileButton
- CKEDITOR.ui.dialog.hbox
- CKEDITOR.ui.dialog.html
- CKEDITOR.ui.dialog.labeledElement
- CKEDITOR.ui.dialog.radio
- CKEDITOR.ui.dialog.select
- CKEDITOR.ui.dialog.textarea
- CKEDITOR.ui.dialog.textInput
- CKEDITOR.ui.dialog.uiElement
- CKEDITOR.ui.dialog.vbox
- CKEDITOR.ui.handlerDefinition
- CKEDITOR.xml

# Class CKEDITOR.pluginDefinition

Defined in: core/plugindefinition.js.

Class Summary
Constructor Attributes | Constructor Name and Description
--- | ---
| CKEDITOR.pluginDefinition() (Virtual Class) Do not call this constructor.

Field Summary
Field Attributes | Field Name and Description
--- | ---
| requires A list of plugins that are required by this plugin.

Method Summary
Method Attributes | Method Name and Description
--- | ---
| beforeInit(editor) Function called on initialization of every editor instance created in the page before the init() call task.
| init(editor) Function called on initialization of every editor instance created in the page.

Class Detail
CKEDITOR.pluginDefinition()
Since: 3.0
(Virtual Class) Do not call this constructor. This class is not really part of the API. It just illustrates the features of plugin objects to be passed to the CKEDITOR.plugins.add function.
Field Detail
{Array} requires
Since: 3.0
A list of plugins that are required by this plugin. Note that this property doesn't guarantee the loading order of the plugins.

    CKEDITOR.plugins.add( 'sample',
    {
        requires : [ 'button', 'selection' ]
    });

Method Detail
{Undefined} beforeInit(editor)
Since: 3.0
Function called on initialization of every editor instance created in the page before the init() call task. The beforeInit function will be called for all plugins, after that the init function is called for all of them. This feature makes it possible to initialize things that could be used in the init function of other plugins.

    CKEDITOR.plugins.add( 'sample',
    {
        beforeInit : function( editor )
        {
            alert( 'Editor "' + editor.name + '" is to be initialized!' );
        }
    });

Parameters:
{CKEDITOR.editor} editor
  The editor instance being initialized.

{Undefined} init(editor)
Since: 3.0
Function called on initialization of every editor instance created in the page.

    CKEDITOR.plugins.add( 'sample',
    {
        init : function( editor )
        {
            alert( 'Editor "' + editor.name + '" is being initialized!' );
        }
    });

Parameters:
{CKEDITOR.editor} editor
  The editor instance being initialized.

Copyright © 2003-2009, CKSource - Frederico Knabben. All rights reserved.