\Kendo\UI\FileManagerContextMenu

A PHP class representing the contextMenu setting of FileManager.

Methods

addItem

Adds one or more FileManagerContextMenuItem to the FileManagerContextMenu.

Returns

\Kendo\UI\FileManagerContextMenu

Parameters

$value[, $value2, ...] \Kendo\UI\FileManagerContextMenuItem|array

Example - using \Kendo\UI\FileManagerContextMenuItem

<?php
$contextMenu = new \Kendo\UI\FileManagerContextMenu();
$item = new \Kendo\UI\FileManagerContextMenuItem();
$command = 'value';
$item->command($command);
$contextMenu->addItem($item);
?>

Example - using array

<?php
$contextMenu = new \Kendo\UI\FileManagerContextMenu();
$command = 'value';
$contextMenu->addItem(array('command' => $command));
?>

Example - adding more than one FileManagerContextMenuItem

<?php
$contextMenu = new \Kendo\UI\FileManagerContextMenu();
$first  = new \Kendo\UI\FileManagerContextMenuItem();
$second = new \Kendo\UI\FileManagerContextMenuItem();
$contextMenu->addItem($first, $second);
?>
In this article
Not finding the help you need?