27require
'config.inc.php';
28require
'connector.lib.php';
30if (!$Config[
'Enabled']) {
31 SendError(1,
'This connector is disabled. Please check the "editor/filemanager/connectors/php/config.inc.php" file');
43 if (!isset($_GET[
'Command']) || !isset($_GET[
'Type']) || !isset($_GET[
'CurrentFolder'])) {
49 $sResourceType =
GETPOST(
'Type');
50 $sCurrentFolder = GetCurrentFolder();
53 if (!IsAllowedCommand($sCommand)) {
54 SendError(1,
'The "'.$sCommand.
'" command isn\'t allowed');
57 if (!IsAllowedType($sResourceType)) {
58 SendError(1,
'Invalid type specified');
62 if ($sCommand ==
'FileUpload') {
63 FileUpload($sResourceType, $sCurrentFolder, $sCommand);
67 CreateXmlHeader($sCommand, $sResourceType, $sCurrentFolder);
72 GetFolders($sResourceType, $sCurrentFolder);
74 case 'GetFoldersAndFiles':
75 GetFoldersAndFiles($sResourceType, $sCurrentFolder);
78 CreateFolder($sResourceType, $sCurrentFolder);
This class is used to manage file upload using ajax.
GETPOST($paramname, $check='alphanohtml', $method=0, $filter=null, $options=null, $noreplace=0)
Return value of a param into GET or POST supervariable.