Environment Variables

The CMS will set these variables on your plugin before calling your init() and showSlot() methods. They give you information about where plugin is currently running from.

You can use syntax of the form:

$this->variableName

to access these variables from your PHP code.

$this->cID

The id of the current content item.

$this->containerId

The HTML/DOM id of the div element that your Plugin has been placed in.

$this->cType

The type of the current content item, e.g. documenthtmlpicture...

$this->cVersion

When an admin or a visitor is looking at a content item, this contains the version of a content item which is currently in view.

In visitor mode this will always be equal to the cms_core::$visitorVersion variable.

$this->eggId

The nested id of your Plugin, if your Plugin is placed in a Nest.