Suggestions??

Suggestions??

by Jim Edgar -
Number of replies: 2

Hi all,

Any advice on how to get rid of the following message in the "Adding a new  Hot Potatoes quiz" screen would be greatly appreciated:

Fatal error: Call to undefined function: button_to_popup_window() in /home/jedgar/public_html/moodle/mod/hotpot/mod.html on line 84

There is no "Browse" button available to choose the hot potatoes file.

I have installed and re-installed the hotpot module several times to correct the problem, but without luck. The version of Moodle I'm using is 1.1.1; the hotpot module is 1.3.5.

Also, in my (feeble) attempt to upgrade to a newer version of Moodle (using Fantastico), I backed up the courses, but not the hotpot mod. I then deleted the hotpot module, to try the upgrade. The upgrade failed, giving me the following message:

Upgrading...

Initializing Parameters - Done.mysqldump: Got error: 2005: Unknown MySQL Server Host 'CFG-' (1) when trying to connect sh: //: is a directory sh: //: is a directory sh: //: is a directory sh: //: is a directory

Upgrade failed

The database CFG->dbname = "jedgar_mdle1"; // database name, eg moodle is not working properly and the creation of a database backup file has failed. Please contact the sysadmin for further assistance. Include this message for reference.

And to make matters worse, when I tried to restore the back-up, I figured out the hotpot exercises were not included - leaving me with no chouice but to rebuild/link the courses' hotpot files - roughly  several hundred sad .

Any assisstance/advice would be welcomed.

Jim

Average of ratings: -
In reply to Jim Edgar

Re: Suggestions??

by Thomas Robb -
I've just posted a revision which includes a new 'mod.html' file although the error that you cite is new to me. Please try the new file and see if it cures the problem.

I'm sorry to say that I still haven't included backup capability with the hotpot module, but I am working on it. I should have a working version before the end of September, although this won't help Jim.

If you are familiar with the mysql database, however, you might be able to transfer all of the files from one database or course to another, particularly if you are not interested in keeping the associated user records. You can transfer the entire mdl_hotpot table to your new database manually. Once this has been done, then you will need to modify the course number for each entry *if* the course number has changed. You can do this semi-automatically. For example, in the old database, if the course id was 3 and now it should be 4, you do this:

update mdl_hotpot set course = 4 where course = 3

There is another table mdl_course_modules that has a single line entry for each hotpot instance. You might be able to extract these from your old table and add them to the new one. The 'course' field has to be modified as above. In additon, the 'instance' field has to contain the 'id' number of the activity from the mdl_hotpot table. There is a slight chance that the module number for 'hotpot' might have also changed. You can see what the current module number for hotpot activities is by checking the 'id' in the mdl_modules table.

Even with all of this fiddling, however, you will still have to modify the start and end dates manually for each activity, unless old times are still applicable to your new school term.

I hope this helps.

In reply to Jim Edgar

Re: Suggestions??

by Marc Graham -
I had the same problem.  fixed it by removing space in the mod.html file line 85 ?? or 84...  between w and (
it now reads
button_to_popup_window("/mod....

btw, we're still on 1.1.1 of moodle