MDL-28701 some more tempdirs updated
This commit is contained in:
@@ -68,7 +68,7 @@ if ($data = $mform->get_data()) {
|
||||
|
||||
$realfilename = $mform->get_new_filename('questionfile');
|
||||
//TODO: Leave all imported questions in Questionimport for now.
|
||||
$importfile = "{$CFG->dataroot}/temp/questionimport/{$realfilename}";
|
||||
$importfile = "{$CFG->tempdir}/questionimport/{$realfilename}";
|
||||
make_temp_directory('questionimport');
|
||||
if (!$result = $mform->save_file('questionfile', $importfile, true)) {
|
||||
throw new moodle_exception('uploadproblem');
|
||||
|
||||
+1
-1
@@ -83,7 +83,7 @@ if ($form = $import_form->get_data()) {
|
||||
// or one from the filesarea.
|
||||
$realfilename = $import_form->get_new_filename('newfile');
|
||||
|
||||
$importfile = "{$CFG->dataroot}/temp/questionimport/{$realfilename}";
|
||||
$importfile = "{$CFG->tempdir}/questionimport/{$realfilename}";
|
||||
make_temp_directory('questionimport');
|
||||
if (!$result = $import_form->save_file('newfile', $importfile, true)) {
|
||||
throw new moodle_exception('uploadproblem');
|
||||
|
||||
Reference in New Issue
Block a user