MDL-36754 core_files: Add a token version of pluginfile
This commit is contained in:
+6
-2
@@ -25,12 +25,16 @@
|
||||
*/
|
||||
|
||||
// Disable moodle specific debug messages and any errors in output.
|
||||
define('NO_DEBUG_DISPLAY', true);
|
||||
if (!defined('NO_DEBUG_DISPLAY')) {
|
||||
define('NO_DEBUG_DISPLAY', true);
|
||||
}
|
||||
|
||||
require_once('config.php');
|
||||
require_once('lib/filelib.php');
|
||||
|
||||
$relativepath = get_file_argument();
|
||||
if (empty($relativepath)) {
|
||||
$relativepath = get_file_argument();
|
||||
}
|
||||
$forcedownload = optional_param('forcedownload', 0, PARAM_BOOL);
|
||||
$preview = optional_param('preview', null, PARAM_ALPHANUM);
|
||||
// Offline means download the file from the repository and serve it, even if it was an external link.
|
||||
|
||||
Reference in New Issue
Block a user