How to install new module to Moodle

Moodle is being said to be great at modular way for adding new features. Adding a new module or block is fairly easy, follow my step by step tutorial.

You may find, that default Moodle installation cannot do something you want to. The most complete source of new and up-to-date modules and contributions is to be found here

As you will notice, there are about 280+ contributions, that's a really a lot ! :) Let's suppose, you want to send mails directly from Moodle to students of your course. You can do it with forum, you may say, but if you want to send mail only to selected users? How do you do that?

I found third party block Quickmail really useful. You can add it as a block to your course and send mail to students of this course. You can select, if only a teacher can send mails (recommended) or even the students etc. How do you install this block?

First of all, you need to download it to your computer. That's easy ;) . Just take care you are downloading right one for your current Moodle version. I will be installing it to Moodle 1.8

Next step is to unpack zipped file you downloaded. I am using Total Commander on my home computer with Windows XP installed. Unzipping with it is really easy, you will just locate downloaded file, enter it and copy files there with F5 to some temp directory.

You will find, that block Quickmail consists of directory Quickmail, there are subdirectories db, lang and some files. As may noticed when you were downloading this block from moodle.org, type of this contribution is Block (another type is Module ). This will direct you to what kind directory you should copy new contribution (in this case it's block subdirectory of your moodle installation ).

Next step is upload this unpacked files to your server, to moodle installation source data. You may use some FTP tool, or SCP software, it depends what your hosting provides. You will just copy quickmail directory to blocks subdirectory, similar as you copied moodle installation files to server, when you were installing Moodle for a first time.

Oh, I forgot. Files in lang subdirectory of Quickmail directory should be placed to language pack, your site is using. If you are using en_utf8 pack, you should upload it to your local directory in the moodledata (see previous post here Change language strings in Moodle for letting Moodle create local lang directory. It's better when you will be updating your Moodle next time.)

And we are at the end..now you have to visit Notification page in Site Administration block (You should be logged as admin to do that ). You should be rewarded with some lines that tell you the needed changes in database been carrying out. And voila, you have added your first new block :D.

Just some warnings:
Don't add any new block or module if you don't need them desperately. You will thank yourself, when you will be updating next time, you had not messed up with some old contributions that are not available for a new version of the Moodle. To avoid that case, watch a module download page carefully, if this contribution is not abandoned.

I hope I can be understood, if you have any questions, share them in the comments.

No comments: