Hello all,
I am not a trained/educated programmer nor do I understand most of the changes made from 1.9 to 2.0 so I probably shouldn't even be poking around but...
There is significant demand/desire for a bulk course upload tool like the one that was available for 1.9 (here). Unfortunately the tool doesn't work under 2.0. I've been poking around with errors and debugging turned on in the hopes that I might be able to make some progress. I've made a little but not enough to make a difference.
I removed/replaced all instances of print_header with echo $OUTPUT ->header (done the same with footers) but still am encountering the following error:
Coding error detected, it must be fixed by a programmer: Invalid state passed to moodle_page::set_state. We are in state 2 and state 1 was requested.
The stack trace I'm getting is:
- line 697 of /lib/pagelib.php: coding_exception thrown
- line 600 of /lib/outputrenderers.php: call to moodle_page->set_state()
- line 102 of /admin/uploadcourse.php: call to core_renderer->header()
- line 125 of /admin/uploadcourse.php: call to csverror()
- line 639 of /admin/uploadcourse.php: call to getdefaultcategory()
If anyone could give me a little nudge to point me in the right direction I'd be most appreciative.
Jason