Server IP : 80.87.202.40 / Your IP : 216.73.216.169 Web Server : Apache System : Linux rospirotorg.ru 5.14.0-539.el9.x86_64 #1 SMP PREEMPT_DYNAMIC Thu Dec 5 22:26:13 UTC 2024 x86_64 User : bitrix ( 600) PHP Version : 8.2.27 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : ON | Pkexec : ON Directory : /home/bitrix/ext_www/rospirotorg.ru/bitrix/modules/burlakastudio.realcommenter/ajax/ |
Upload File : |
<?php use Bitrix\Main\Application; use Bitrix\Main\Localization\Loc; use Burlakastudio\Realcommenter\DEBUGGER; use Burlakastudio\Realcommenter\TOOLS; require_once 'ajax_header_init.php'; if (!$access_granted) { DEBUGGER::error( Loc::getMessage('DOMAIN_ACCESS_DENIED') ); $json_return['ERROR'][] = Loc::getMessage('DOMAIN_ACCESS_DENIED'); } else { $APPLICATION->ShowAjaxHead(); $INPUT_NAME = htmlspecialchars($posts['INPUT_NAME']); $CONTROL_ID = htmlspecialchars($posts['CONTROL_ID']); $controlID = htmlspecialchars($posts['controlID']); if (!$INPUT_NAME) { if ($controlID) { $INPUT_NAME = str_replace('BRCMD7_', 'NEW_COMMENT_FILES_', $controlID); } else { $INPUT_NAME = 'NEW_COMMENT_FILES'; } } if (!$CONTROL_ID) { if ($controlID) { $CONTROL_ID = $controlID; } else { $CONTROL_ID = 'BRCMD7'; } } $APPLICATION->IncludeComponent( 'bitrix:main.file.input', 'drag_n_drop', [ 'INPUT_NAME' => $INPUT_NAME, 'CONTROL_ID' => $CONTROL_ID, // 'MAX_FILE_SIZE' => 100000, 'MODULE_ID' => TOOLS::getModuleName() //"ALLOW_UPLOAD" => "F", // A / F + ext / I ], false ); /** * �������� �����, �� �������� � �����, * ����� � ������ ������ �������. * * �� ��� ��� ������ ������� � ��� ����: * - ����� ������������� �������� * - ����� � �������� ������� ����-�� ��� �� �������� / �������� �������� * (�������� ����� drag_n_drop ��������� (������� ���-����� ����������� �� ������)) * * � ��� ������ ����� � ��� ������� ��� ��� $controlID (������ $CONTROL_ID) */ if (!$controlID) { $css = '/bitrix/js/burlakastudio.realcommenter/css/drag_n_drop_overload.css'; $doc_root = Application::getDocumentRoot(); ?> <script> BX.ready(function () { BX.loadCSS('<?= $css?>?x=<?= filemtime($doc_root . $css)?>'); }); </script> <? } }