Upload courses: course format options

Upload courses: course format options

by Michael Ransburg -
Number of replies: 1

Dear all,

I have created a custom course format and added several course format options (http://docs.moodle.org/dev/Course_formats#Course_format_options) to it. I'm now using the "upload courses" feature (http://docs.moodle.org/26/en/Upload_courses) to import courses.

However, I do not seem to be able to also import the additional course format options. I tried adding a column to the import CSV which corresponds to the column name of the additional course format option in the mdl_course_format_options table, however it was not imported.

Is it currently possible to import additional course format options using the "upload courses" feature?

If not, can someone point me into the right direction in order to extend the correct PHP file which handles the uploading of courses?

Many thanks and all the best,

Michael

Average of ratings: -
In reply to Michael Ransburg

Re: Upload courses: course format options

by Michael Ransburg -

Hi all,

sorry for again replying to my own questions.

I figured it out. Should anyone ever need it: You just have to extend the $validfields array at line 96 of /admin/tool/uploadcourse/classes/course.php by your additional course format options. It then correctly imports these options if you add them to your CSV.

All the best,

Michael

Average of ratings: Useful (2)