Difference between revisions of "Moodle Question Type Installation"

From WeBWorK_wiki
Jump to navigation Jump to search
 
(13 intermediate revisions by 4 users not shown)
Line 1: Line 1:
This page presents very detailed instructions on how to install the [[WeBWorKMoodleQuestionType]]. This material assumes a very basic understanding of UNIX shell commands.
 
  +
Installing the [[Moodle Question Type]] is designed to be easy. Assuming you already have the prerequisites this should take about 5 minutes.
   
==Step 1: Getting the Software==
 
  +
While Revision 31 of the code in the Rochester SVN was throwing errors, with the update to Revision 32 the code is reported to work without difficult on install. Thanks to Jerome Charaoui, Matt Petro, Mike Gage and others who assisted in getting the fix and publishing it.
   
Right now there is only one way to acquire the software; downloading from a SVN server. In the future there will be zipped packages available to download off the web.
 
  +
It should be noted that at present WWMQT cannot import question banks (as opposed to requiring an instructor to cut and paste each question into the Moodle question bank), which arguably renders this integration much less economical than it might otherwise be, but that certainly does not mean that it won't be addressed in future. [[User:Net-buoy|Net-buoy]] 21:10, 5 November 2009 (EST)
  +
  +
==Prerequisites==
   
===SVN===
 
  +
* Moodle 1.9 -- http://moodle.org
  +
* PHP5 -- Depending on your system there are many simple ways to install PHP.
  +
* PHP soap extensions -- Can be installed as a package out of debian or out of an rpm, or flagged when PHP is built from source.
  +
* WeBWorK Question Server [optional] -- Find installation instructions at [[WeBWorK Question Server Installation]].
   
This package is hosted at http://question2.webwork.rochester.edu/svn/wwmqt/trunk From most terminals you can run:
 
  +
==Installation==
 
svn co http://question2.webwork.rochester.edu/svn/wwmqt/trunk wwmqt
 
   
This will create a folder named 'wwmqt' in your current working directory. If you are getting a message about the 'svn' command not being found on your machine you need to go ahead and install SVN. Instructions on how to do this for your Linux distribution are readily available by consulting Google.
 
  +
To start you should have administrator access to the Moodle site.
   
==Step 2: Prerequisites==
 
  +
1. Check out a copy of the WeBWorK Moodle Question Type by running the following from a terminal:
  +
svn co http://svn.webwork.maa.org/system/trunk/wwmoodle wwquestion
   
* Moodle 1.8.x
 
  +
This will place a folder named ''wwquestion'' in your current working directory.
* PHP5 with SOAP extensions
 
* Access to a WeBWorKQuestionServer
 
   
More information on how to install Moodle is available on their website: http://moodle.org.
 
  +
2. In the directory wwmqt/bin/setup you should find the perl script setup.pl and config.php.base. Execute setup.pl (remember, you made need to take additional steps to run this script on your system, such as invoking sudo, etc.) The script essentially configures an appropriate config.php file for you and then deletes prior copies of wwmqt files and then installs new copies of the files. If you do not wish to install a WeBWorK Question Server on your own machine you can use a communal server and addresses you can provide to the script in this case can be found at [[WeBWorK Question Server]].
   
PHP5 can be found using the Linux package management systems. The additional SOAP extension can be found in the same manner. If you need to install PHP and/or the SOAP extensions you will need to restart Apache.
 
  +
If you wish, you can review the contents of the setup.pl script and address the few actions taken by it manually.
   
==Step 3: Setup Script==
 
  +
3. Login to the Moodle site and click on ''Notifications'' in the Site Administration panel on the left. The database tables should now be created.
   
Now you need to run the setup script. This is located under wwmqt/bin/setup. The following code will run the setup script.
 
  +
That's it. Your done! Everything can be tested by trying to load and preview a WeBWorK question.
   
cd wwmqt/bin/setup
 
  +
Look at the [[Moodle Question Type FAQ]] if you have any questions.
sudo perl setup.pl
 
   
Answer the questions or use the defaults in hard brackets. To use the defaults just leave the questions blank. Use the WSDL path from the WeBWorKQuestionServer that you are using.
 
   
==Step 4: Post Install==
 
  +
[[Category:Moodle_Integration]]
 
You now need to go to the Site Administration panel in your Moodle installation. Click on Notifications. Moodle should now setup the database tables associated with the WWMQT.
 
 
That's it your done!
 
 
[[Category:Moodle_Question_Type]]
 

Latest revision as of 09:53, 19 October 2012

Installing the Moodle Question Type is designed to be easy. Assuming you already have the prerequisites this should take about 5 minutes.

While Revision 31 of the code in the Rochester SVN was throwing errors, with the update to Revision 32 the code is reported to work without difficult on install. Thanks to Jerome Charaoui, Matt Petro, Mike Gage and others who assisted in getting the fix and publishing it.

It should be noted that at present WWMQT cannot import question banks (as opposed to requiring an instructor to cut and paste each question into the Moodle question bank), which arguably renders this integration much less economical than it might otherwise be, but that certainly does not mean that it won't be addressed in future. Net-buoy 21:10, 5 November 2009 (EST)

Prerequisites

  • Moodle 1.9 -- http://moodle.org
  • PHP5 -- Depending on your system there are many simple ways to install PHP.
  • PHP soap extensions -- Can be installed as a package out of debian or out of an rpm, or flagged when PHP is built from source.
  • WeBWorK Question Server [optional] -- Find installation instructions at WeBWorK Question Server Installation.

Installation

To start you should have administrator access to the Moodle site.

1. Check out a copy of the WeBWorK Moodle Question Type by running the following from a terminal:

   svn co http://svn.webwork.maa.org/system/trunk/wwmoodle wwquestion

This will place a folder named wwquestion in your current working directory.

2. In the directory wwmqt/bin/setup you should find the perl script setup.pl and config.php.base. Execute setup.pl (remember, you made need to take additional steps to run this script on your system, such as invoking sudo, etc.) The script essentially configures an appropriate config.php file for you and then deletes prior copies of wwmqt files and then installs new copies of the files. If you do not wish to install a WeBWorK Question Server on your own machine you can use a communal server and addresses you can provide to the script in this case can be found at WeBWorK Question Server.

If you wish, you can review the contents of the setup.pl script and address the few actions taken by it manually.

3. Login to the Moodle site and click on Notifications in the Site Administration panel on the left. The database tables should now be created.

That's it. Your done! Everything can be tested by trying to load and preview a WeBWorK question.

Look at the Moodle Question Type FAQ if you have any questions.