本文整理汇总了PHP中FileManager::fireEvent方法的典型用法代码示例。如果您正苦于以下问题:PHP FileManager::fireEvent方法的具体用法?PHP FileManager::fireEvent怎么用?PHP FileManager::fireEvent使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类FileManager
的用法示例。
在下文中一共展示了FileManager::fireEvent方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: select
function select()
{
// Check for request forgeries
if (!JSession::checkToken('request')) {
echo json_encode(array('status' => '0', 'error' => JText::_('JINVALID_TOKEN')));
return;
}
// Get the user
$user = JFactory::getUser();
$params = JComponentHelper::getParams('com_j2xml');
$remote_folder = $params->get('remote_folder', '../media/com_j2xml/files');
jimport('eshiol.filemanager.filemanager');
$browser = new FileManager(array('directory' => $remote_folder));
$browser->fireEvent(!empty($_GET['event']) ? $_GET['event'] : null);
}
示例2: UploadIsAuthenticated
<?php
include '../Backend/FileManager.php';
// Please add your own authentication here
function UploadIsAuthenticated($get)
{
if (!empty($get['session'])) {
return true;
}
return false;
}
$browser = new FileManager(array('directory' => 'Files/', 'assetBasePath' => '../Assets', 'upload' => false, 'destroy' => false));
$browser->fireEvent(!empty($_GET['event']) ? $_GET['event'] : null);
示例3: UploadIsAuthenticated
<?php
include $pluginpath . 'inc/FileManager/Backend/FileManager.php';
// Please add your own authentication here
function UploadIsAuthenticated($get)
{
if (!empty($get['session'])) {
return true;
}
return false;
}
$fieldtype = isset($_REQUEST['fieldtype']) ? $_REQUEST['fieldtype'] : '';
$bloxProps = isset($_REQUEST['bloxProps']) ? $_REQUEST['bloxProps'] : '';
$directory = $xedit->makeFileManagerPath($fieldtype, $bloxProps);
$parts = explode('/', $directory);
unset($parts[count($parts) - 1]);
$url = count($parts) > 0 ? implode('/', $parts) . '/' : '';
$browser = new FileManager(array('directory' => $basePath . 'assets/' . $directory, 'assetBasePath' => $basePath . 'assets/plugins/xedit/inc/FileManager/Assets', 'domain' => $modx->config['site_url'], 'baseURL' => 'assets/' . $url, 'upload' => true, 'destroy' => true));
//$modx->logEvent(0, 1, print_r($_REQUEST,true) , 'filemanager');
$browser->fireEvent(!empty($_REQUEST['event']) ? $_REQUEST['event'] : null);