28require
'config.inc.php';
29require
'connector.lib.php';
31if (!$Config[
'Enabled']) {
32 SendError(1,
'This connector is disabled. Please check the "editor/filemanager/connectors/php/config.inc.php" file');
44 if (!isset($_GET[
'Command']) || !isset($_GET[
'Type']) || !isset($_GET[
'CurrentFolder'])) {
50 $sResourceType =
GETPOST(
'Type');
51 $sCurrentFolder = GetCurrentFolder();
54 if (!IsAllowedCommand($sCommand)) {
55 SendError(1,
'The "'.$sCommand.
'" command isn\'t allowed');
58 if (!IsAllowedType($sResourceType)) {
59 SendError(1,
'Invalid type specified');
63 if ($sCommand ==
'FileUpload') {
64 FileUpload($sResourceType, $sCurrentFolder, $sCommand);
69 CreateXmlHeader($sCommand, $sResourceType, $sCurrentFolder);
74 GetFolders($sResourceType, $sCurrentFolder);
76 case 'GetFoldersAndFiles':
77 GetFoldersAndFiles($sResourceType, $sCurrentFolder);
80 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.