<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://docs.moodle.org/test/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Daniss</id>
	<title>MoodleDocs - User contributions [en]</title>
	<link rel="self" type="application/atom+xml" href="https://docs.moodle.org/test/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Daniss"/>
	<link rel="alternate" type="text/html" href="https://docs.moodle.org/test/Special:Contributions/Daniss"/>
	<updated>2026-10-09T04:18:44Z</updated>
	<subtitle>User contributions</subtitle>
	<generator>MediaWiki 1.43.5</generator>
	<entry>
		<id>https://docs.moodle.org/test/index.php?title=Internal_enrolment&amp;diff=47976</id>
		<title>Internal enrolment</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/test/index.php?title=Internal_enrolment&amp;diff=47976"/>
		<updated>2008-12-10T14:00:01Z</updated>

		<summary type="html">&lt;p&gt;Daniss: /* Enforcing enrolment key usage */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Location: Internal enrolment edit settings link in &#039;&#039;Administration &amp;gt; Courses &amp;gt; [[Enrolment plugins|Enrolments]]&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Self-enrolment==&lt;br /&gt;
By default, students can enrol themselves on whatever courses they choose. They do so by clicking on the course name then answering yes to the question &amp;quot;You are about to enrol yourself as a member of this course. Are you sure you wish to do this?&amp;quot; You can restrict users from enrolling on whatever courses they choose by setting an [[Enrolment key|enrolment key]].&lt;br /&gt;
&lt;br /&gt;
A trick to avoid the confirmation message is to make a link to the course with &#039;&amp;amp;confirm=1&#039;  on the end after enrol.php e.g. &amp;lt;nowiki&amp;gt;http://moodle.org/course/enrol.php?id=50&amp;amp;confirm=1&amp;lt;/nowiki&amp;gt; Which will take you straight to the course page and enrol you transparently.&lt;br /&gt;
&lt;br /&gt;
==Role of key holder==&lt;br /&gt;
&lt;br /&gt;
{{Moodle 1.8}}In Moodle 1.8.3 onwards the role of keyholder may be set. This only affects the screen that students will see when they attempt to enrol on a course where an enrolment key is specified. The screen will list anybody who is assigned to the specified role (in the course context) as contacts to request the enrolment key. If this is not set (the default) or there is nobody assigned to the role in a given course the &amp;quot;old&amp;quot; behaviour is used, which is to display the name of the first person with update privilege for the course. &lt;br /&gt;
&lt;br /&gt;
==Enrolment key hint==&lt;br /&gt;
&lt;br /&gt;
{{Moodle 1.9}}In Moodle 1.9.3 onwards, the enrolment key hint (the first character of the enrolment key) may be disabled by setting &#039;&#039;enrol_manual_showhint&#039;&#039; to No.&lt;br /&gt;
&lt;br /&gt;
==Enforcing enrolment key complexity==&lt;br /&gt;
&lt;br /&gt;
{{Moodle 1.9}}In Moodle 1.9.4 onwards, enrolment key complexity may be enforced according to the site password policy by setting &#039;&#039;enrol_manual_usepasswordpolicy&#039;&#039; to Yes. (The site password policy is set in &#039;&#039;Administration &amp;gt; Security &amp;gt; [[Site policies]]&#039;&#039;.)&lt;br /&gt;
&lt;br /&gt;
==Enforcing enrolment key usage==&lt;br /&gt;
&lt;br /&gt;
{{Moodle 1.9}}In Moodle 1.9.4 onwards, the use of enrolment keys in new courses may be enforced by setting &#039;&#039;enrol_manual_requirekey&#039;&#039; to Yes. This will also result in teachers being prevented from removing enrolment keys from existing courses.&lt;br /&gt;
&lt;br /&gt;
[[Category:Enrolment]]&lt;br /&gt;
&lt;br /&gt;
[[fr:Inscription interne]]&lt;/div&gt;</summary>
		<author><name>Daniss</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/test/index.php?title=Talk:Roadmap&amp;diff=43009</id>
		<title>Talk:Roadmap</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/test/index.php?title=Talk:Roadmap&amp;diff=43009"/>
		<updated>2008-09-01T10:46:21Z</updated>

		<summary type="html">&lt;p&gt;Daniss: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Minimum PHP requirement==&lt;br /&gt;
&lt;br /&gt;
Moodle 2.0 will require PHP 5.2.4 as a minimum (see: MDL-15410)&lt;br /&gt;
&lt;br /&gt;
==Student Information API for version 2.0==&lt;br /&gt;
&lt;br /&gt;
Also on a related point the student API which is down for version 2.0. Is there any more detail to here on this yet? Will this be part of the IMS Enterprise data model and therefore enrolments plug in or will someone be working on a Moodle SIF agent? In the UK SIF is likely to take off as the DfES via Becta are currently consulting on a UK SIF model and piloting SIF in Birmingham and Northern Ireland. I believe that SIF is used quite widely in the US?&lt;br /&gt;
&lt;br /&gt;
== Wiki engine ==&lt;br /&gt;
&lt;br /&gt;
I noticed there was some talk about making new wiki module for 1.9... what do &amp;quot;nWiki&amp;quot; and &amp;quot;DF wiki&amp;quot; refer to?  I&#039;ve searched online and haven&#039;t found a clear description of what these mean.  I am curious if they are still based on MediaWiki.  I would hate to see some of the great features of MediaWiki (mainly the scalability) be lost.  When MediaWiki is configured with Memcached and Squid caching servers, they can serve thousands of requests per second: hard to beat!&amp;lt;br/&amp;gt;&lt;br /&gt;
Thanks,&amp;lt;br/&amp;gt;&lt;br /&gt;
-[[User:Sean Colombo|Sean Colombo]] 00:12, 13 January 2008 (CST)&lt;br /&gt;
&lt;br /&gt;
None of the wikis are based on Mediawiki.  Mediawiki is very difficult to use as a basis for a Moodle wiki, because of all the special features we need.   [[User:Martin Dougiamas|Martin Dougiamas]] 22:10, 22 April 2008 (CDT)&lt;br /&gt;
&lt;br /&gt;
== about nwiki ==&lt;br /&gt;
&lt;br /&gt;
Seems that nwiki will be inside for 2.0. &lt;br /&gt;
Nwiki IMPLEMENTS the mediawiki markup, and the old features of the current wiki for backwards compatibility... and that is what makes it so difficult. Is really hard. &lt;br /&gt;
&lt;br /&gt;
You migth get by the Using moodle wiki forum and we can discuss about it.&lt;br /&gt;
Cheers. &lt;br /&gt;
--[[User:Ludo (Marc Alier)|Ludo (Marc Alier)]] 11:14, 13 January 2008 (CST)&lt;br /&gt;
&lt;br /&gt;
== About WS ?  ==&lt;br /&gt;
&lt;br /&gt;
Where fit the WS layer in the roadmap?&lt;br /&gt;
&lt;br /&gt;
== IMS LIT 2.0 compliance ? ==&lt;br /&gt;
&lt;br /&gt;
*Wimba is working with IMS to develop an activity module that acts as a consumer of the IMS LTI 2.0 standard...&lt;br /&gt;
*We in UPC (dfwikiteam) are working in a way to make the moodle course a IMS LTI 2.0 producer ... &lt;br /&gt;
shall this be included somewhere in the roadmap?--[[User:Ludo (Marc Alier)|Ludo (Marc Alier)]] 01:05, 9 April 2008 (CDT)&lt;br /&gt;
&lt;br /&gt;
== Site-wide groups ==&lt;br /&gt;
Site-wide (or, preferrable, context-wide) groups is much needed improvement (see votes for MDL-11826), especially in large institutions. Can it be targeted to 2.0?&lt;br /&gt;
&lt;br /&gt;
Yes, it would really help lot of people...&lt;br /&gt;
--[[User:Séverin Terrier|Séverin Terrier]] 16:57, 13 May 2008 (CDT)&lt;br /&gt;
&lt;br /&gt;
MDL-15416 seems to have been tagged for 2.0 by Petr :) [[User:Matt Gibson|Matt Gibson]] 10:46, 19 May 2008 (CDT)&lt;br /&gt;
&lt;br /&gt;
==Minted course profile plugin==&lt;br /&gt;
This was scheduled for 1.9, but didn&#039;t make it. Any plans to include it in 2.0? It seems to have vanished. [[User:Matt Gibson|Matt Gibson]] 10:47, 19 May 2008 (CDT)&lt;br /&gt;
&lt;br /&gt;
== Instructor-led Training Session Management ==&lt;br /&gt;
&lt;br /&gt;
In several of the projects we work on there is a very real need to manage instructor-led sessions by booking training rooms and assigning trainers. I&#039;ve always felt that Moodle is so advanced in many areas but this is something that is not really catered for. Developing this will mean that Moodle can comfortably handle blended-learning.&lt;br /&gt;
&lt;br /&gt;
There has been some fantastic work done on the Face-to-Face contrib module and the integration of the MRBS module. But in my experience, what&#039;s needed is actually a combination of the two systems that integrates to the Moodle calandar and other standard components.&lt;br /&gt;
&lt;br /&gt;
I&#039;d be happy to spec out the requirements and test in real environments.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Craig Meltzer &lt;br /&gt;
[http://moodle.org/user/view.php?id=34863&amp;amp;course=1]&lt;br /&gt;
&lt;br /&gt;
==Subscribe at the thread level &amp;amp; Book Module==&lt;br /&gt;
&lt;br /&gt;
I notice in the tracker http://tracker.moodle.org/browse/MDL-1626 there is a request for the ability for notification (subscription) at the thread level, not just the forum level.&lt;br /&gt;
It says it is in 2.0 in the tracker.&lt;br /&gt;
What does this mean?  Is this definite, since it is not mentioned in the roadmap?  Is it too &#039;&#039;small&#039;&#039; an enhancement to justify comment in the roadmap?  To what level of detail does the roadmap get maintained?&lt;br /&gt;
&lt;br /&gt;
I note there is a request for the book module to be in the core.  http://tracker.moodle.org/browse/CONTRIB-283  But it does not have a fix version indicated.  Does that mean the request is not considered significant to be included in 2.0?? --[[User:Derek Chirnside|Derek Chirnside]] 02:56, 6 July 2008 (CDT)&lt;br /&gt;
&lt;br /&gt;
==Blog &amp;amp; Comments in 2.0==&lt;br /&gt;
&lt;br /&gt;
This is a similar comment to above.  There is a lot of talk about blogs on the various forums here in Moodle.org, and in particular the Moodle implmentation of them.&lt;br /&gt;
&lt;br /&gt;
Particularly here: http://moodle.org/mod/forum/discuss.php?d=94623#p418128 and here: http://moodle.org/mod/forum/discuss.php?d=44830&amp;amp;mode=3&lt;br /&gt;
&lt;br /&gt;
There is an issue tracker here: http://tracker.moodle.org/browse/MDL-8776 but there doesn&#039;t seem to be any sort of focus to the discussion in the details.  From the roadmap: comments are coming.  What about the other suggestions in the tracker?  Where do we find out what is coming and what is planned?  How are decisions arrived at?&lt;br /&gt;
&lt;br /&gt;
I&#039;m curious about the OU blogs as well. --[[User:Derek Chirnside|Derek Chirnside]] 03:13, 6 July 2008 (CDT)&lt;br /&gt;
&lt;br /&gt;
==No longer called Activitiy locking==&lt;br /&gt;
&lt;br /&gt;
Now called: Conditional activities.  I like this terminology change.  Activity locking is a little more draconican and control sounding.  And there is good reason to avoid the term &amp;quot;Selective Release&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
I&#039;d really like it to be very very simple.  A linear pathway being easy to construct, with any possible complex stuff hidden in an advanced tab.  Most of what the lecturers do here is like that.  --[[User:Derek Chirnside|Derek Chirnside]] 03:18, 6 July 2008 (CDT)&lt;/div&gt;</summary>
		<author><name>Daniss</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/test/index.php?title=Development:lib/formslib.php_Validation&amp;diff=36508</id>
		<title>Development:lib/formslib.php Validation</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/test/index.php?title=Development:lib/formslib.php_Validation&amp;diff=36508"/>
		<updated>2008-05-21T16:27:18Z</updated>

		<summary type="html">&lt;p&gt;Daniss: /* moodleform::validation() */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Formslib}}&lt;br /&gt;
&lt;br /&gt;
There are two ways to add validation in the forms lib.&lt;br /&gt;
&lt;br /&gt;
== MoodleQuickForm::addRule() ==&lt;br /&gt;
&lt;br /&gt;
You use this typically inside your moodleform::definition method. For example to set a field as required.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
        $mform-&amp;gt;addElement(&#039;text&#039;,&#039;shortname&#039;, get_string(&#039;shortname&#039;),&#039;maxlength=&amp;quot;15&amp;quot; size=&amp;quot;10&amp;quot;&#039;);&lt;br /&gt;
        $mform-&amp;gt;setHelpButton(&#039;shortname&#039;, array(&#039;courseshortname&#039;, get_string(&#039;shortname&#039;)), true);&lt;br /&gt;
        $mform-&amp;gt;setDefault(&#039;shortname&#039;, get_string(&#039;defaultcourseshortname&#039;));&lt;br /&gt;
        $mform-&amp;gt;addRule(&#039;shortname&#039;, null, &#039;required&#039;, null, &#039;client&#039;);&lt;br /&gt;
        $mform-&amp;gt;setType(&#039;shortname&#039;, PARAM_MULTILANG);&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
There is good documentation for this on the [http://pear.php.net/manual/en/package.html.html-quickform.intro-validation.php PEAR web site]&lt;br /&gt;
&lt;br /&gt;
In Moodle formslib you can set certain rules&#039; error message to null and a default error message will automatically be used. The default messages are defined in lang/{language}/form.php. Here are the English definitions :&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
$string[&#039;err_alphanumeric&#039;]=&#039;You must enter only letters or numbers here.&#039;;&lt;br /&gt;
$string[&#039;err_email&#039;]=&#039;You must enter a valid email address here.&#039;;&lt;br /&gt;
$string[&#039;err_lettersonly&#039;]=&#039;You must enter only letters here.&#039;;&lt;br /&gt;
$string[&#039;err_maxlength&#039;]=&#039;You must enter not more than $a-&amp;gt;format characters here.&#039;;&lt;br /&gt;
$string[&#039;err_minlength&#039;]=&#039;You must enter at least $a-&amp;gt;format characters here.&#039;;&lt;br /&gt;
$string[&#039;err_nopunctuation&#039;]=&#039;You must enter no punctuation characters here.&#039;;&lt;br /&gt;
$string[&#039;err_nonzero&#039;]=&#039;You must enter a number not starting with a 0 here.&#039;;&lt;br /&gt;
$string[&#039;err_numeric&#039;]=&#039;You must enter a number here.&#039;;&lt;br /&gt;
$string[&#039;err_rangelength&#039;]=&#039;You must enter between {$a-&amp;gt;format[0]} and {$a-&amp;gt;format[1]} characters here.&#039;;&lt;br /&gt;
$string[&#039;err_required&#039;]=&#039;You must supply a value here.&#039;;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== moodleform::validation() ==&lt;br /&gt;
&lt;br /&gt;
Define a method validation on your moodleform child to make your own custom validation for the form. This is done on the client side. And data_submitted will return null until the function returns no errors. You return an array of errors if there is any error or an empty array if there are no errors.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
class course_edit_form extends moodleform {&lt;br /&gt;
&lt;br /&gt;
    function definition() {&lt;br /&gt;
        blah blah;&lt;br /&gt;
    }&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
/// perform some extra moodle validation&lt;br /&gt;
    function validation($data) {&lt;br /&gt;
        $errors= array();&lt;br /&gt;
        if ($foundcourses = get_records(&#039;course&#039;, &#039;shortname&#039;, $data[&#039;shortname&#039;])) {&lt;br /&gt;
            if (!empty($data[&#039;id&#039;])) {&lt;br /&gt;
                unset($foundcourses[$data[&#039;id&#039;]]);&lt;br /&gt;
            }&lt;br /&gt;
            if (!empty($foundcourses)) {&lt;br /&gt;
                foreach ($foundcourses as $foundcourse) {&lt;br /&gt;
                    $foundcoursenames[] = $foundcourse-&amp;gt;fullname;&lt;br /&gt;
                }&lt;br /&gt;
                $foundcoursenamestring = implode(&#039;,&#039;, $foundcoursenames);&lt;br /&gt;
                $errors[&#039;shortname&#039;]= get_string(&#039;shortnametaken&#039;, &#039;&#039;, $foundcoursenamestring);&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
&lt;br /&gt;
        if (empty($data[&#039;enrolenddisabled&#039;])){&lt;br /&gt;
            if ($data[&#039;enrolenddate&#039;] &amp;lt;= $data[&#039;enrolstartdate&#039;]){&lt;br /&gt;
                $errors[&#039;enroldateendgrp&#039;] = get_string(&#039;enrolenddaterror&#039;);&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
        return $errors;&lt;br /&gt;
    }&lt;br /&gt;
}&lt;br /&gt;
?&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{Moodle 1.9}}There is a new parameter $files in Moodle 1.9, it allows validation of uploaded files too.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
    function validation($data, $files) {&lt;br /&gt;
        $errors = parent::validation($data, $files);&lt;br /&gt;
        if (empty($files[&#039;userfile&#039;])) {&lt;br /&gt;
            if (array_key_exists(&#039;url&#039;, $data)) {&lt;br /&gt;
                $errors[&#039;url&#039;] = get_string(&#039;required&#039;);&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
        return $errors;&lt;br /&gt;
    }&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>Daniss</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/test/index.php?title=Development:lib/formslib.php_Validation&amp;diff=36501</id>
		<title>Development:lib/formslib.php Validation</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/test/index.php?title=Development:lib/formslib.php_Validation&amp;diff=36501"/>
		<updated>2008-05-21T12:41:04Z</updated>

		<summary type="html">&lt;p&gt;Daniss: /* moodleform::validation() */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Formslib}}&lt;br /&gt;
&lt;br /&gt;
There are two ways to add validation in the forms lib.&lt;br /&gt;
&lt;br /&gt;
== MoodleQuickForm::addRule() ==&lt;br /&gt;
&lt;br /&gt;
You use this typically inside your moodleform::definition method. For example to set a field as required.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
        $mform-&amp;gt;addElement(&#039;text&#039;,&#039;shortname&#039;, get_string(&#039;shortname&#039;),&#039;maxlength=&amp;quot;15&amp;quot; size=&amp;quot;10&amp;quot;&#039;);&lt;br /&gt;
        $mform-&amp;gt;setHelpButton(&#039;shortname&#039;, array(&#039;courseshortname&#039;, get_string(&#039;shortname&#039;)), true);&lt;br /&gt;
        $mform-&amp;gt;setDefault(&#039;shortname&#039;, get_string(&#039;defaultcourseshortname&#039;));&lt;br /&gt;
        $mform-&amp;gt;addRule(&#039;shortname&#039;, null, &#039;required&#039;, null, &#039;client&#039;);&lt;br /&gt;
        $mform-&amp;gt;setType(&#039;shortname&#039;, PARAM_MULTILANG);&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
There is good documentation for this on the [http://pear.php.net/manual/en/package.html.html-quickform.intro-validation.php PEAR web site]&lt;br /&gt;
&lt;br /&gt;
In Moodle formslib you can set certain rules&#039; error message to null and a default error message will automatically be used. The default messages are defined in lang/{language}/form.php. Here are the English definitions :&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
$string[&#039;err_alphanumeric&#039;]=&#039;You must enter only letters or numbers here.&#039;;&lt;br /&gt;
$string[&#039;err_email&#039;]=&#039;You must enter a valid email address here.&#039;;&lt;br /&gt;
$string[&#039;err_lettersonly&#039;]=&#039;You must enter only letters here.&#039;;&lt;br /&gt;
$string[&#039;err_maxlength&#039;]=&#039;You must enter not more than $a-&amp;gt;format characters here.&#039;;&lt;br /&gt;
$string[&#039;err_minlength&#039;]=&#039;You must enter at least $a-&amp;gt;format characters here.&#039;;&lt;br /&gt;
$string[&#039;err_nopunctuation&#039;]=&#039;You must enter no punctuation characters here.&#039;;&lt;br /&gt;
$string[&#039;err_nonzero&#039;]=&#039;You must enter a number not starting with a 0 here.&#039;;&lt;br /&gt;
$string[&#039;err_numeric&#039;]=&#039;You must enter a number here.&#039;;&lt;br /&gt;
$string[&#039;err_rangelength&#039;]=&#039;You must enter between {$a-&amp;gt;format[0]} and {$a-&amp;gt;format[1]} characters here.&#039;;&lt;br /&gt;
$string[&#039;err_required&#039;]=&#039;You must supply a value here.&#039;;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== moodleform::validation() ==&lt;br /&gt;
&lt;br /&gt;
Define a method validation on your moodleform child to make your own custom validation for the form. This is done on the client side. And data_submitted will return null until the function returns no errors. You return an array of errors if there is any error or an empty array if there are no errors.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
class course_edit_form extends moodleform {&lt;br /&gt;
&lt;br /&gt;
    function definition() {&lt;br /&gt;
        blah blah;&lt;br /&gt;
    }&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
/// perform some extra moodle validation&lt;br /&gt;
    function validation($data) {&lt;br /&gt;
        $errors= array();&lt;br /&gt;
        if ($foundcourses = get_records(&#039;course&#039;, &#039;shortname&#039;, $data[&#039;shortname&#039;])) {&lt;br /&gt;
            if (!empty($data[&#039;id&#039;])) {&lt;br /&gt;
                unset($foundcourses[$data[&#039;id&#039;]]);&lt;br /&gt;
            }&lt;br /&gt;
            if (!empty($foundcourses)) {&lt;br /&gt;
                foreach ($foundcourses as $foundcourse) {&lt;br /&gt;
                    $foundcoursenames[] = $foundcourse-&amp;gt;fullname;&lt;br /&gt;
                }&lt;br /&gt;
                $foundcoursenamestring = implode(&#039;,&#039;, $foundcoursenames);&lt;br /&gt;
                $errors[&#039;shortname&#039;]= get_string(&#039;shortnametaken&#039;, &#039;&#039;, $foundcoursenamestring);&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
&lt;br /&gt;
        if (empty($data[&#039;enrolenddisabled&#039;])){&lt;br /&gt;
            if ($data[&#039;enrolenddate&#039;] &amp;lt;= $data[&#039;enrolstartdate&#039;]){&lt;br /&gt;
                $errors[&#039;enroldateendgrp&#039;] = get_string(&#039;enrolenddaterror&#039;);&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
        return $errors;&lt;br /&gt;
    }&lt;br /&gt;
}&lt;br /&gt;
?&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{Moodle 1.9}}There is a new parameter $files in Moodle 1.9, it allows validation of uploaded files too.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
    function validation($data, $files) {&lt;br /&gt;
        $errors = parent::validate($data, $files);&lt;br /&gt;
        if (empty($files[&#039;userfile&#039;])) {&lt;br /&gt;
            if (array_key_exists(&#039;url&#039;, $data)) {&lt;br /&gt;
                $errors[&#039;url&#039;] = get_string(&#039;required&#039;);&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
        return $errors;&lt;br /&gt;
    }&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>Daniss</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Adding_capabilities&amp;diff=34670</id>
		<title>Development:NEWMODULE Adding capabilities</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Adding_capabilities&amp;diff=34670"/>
		<updated>2008-04-07T16:49:33Z</updated>

		<summary type="html">&lt;p&gt;Daniss: /* Create one access.php file in the &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;/db directory. */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;In order to add a capabilities your &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt; you have to:&lt;br /&gt;
&lt;br /&gt;
==Create one access.php file in the &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;/db directory.==&lt;br /&gt;
&lt;br /&gt;
It must contain&lt;br /&gt;
*the capabilities to be installed and&lt;br /&gt;
*the defaults for each standard role.&lt;br /&gt;
&lt;br /&gt;
A model of what has to be added is: &lt;br /&gt;
    $mod_glossary_capabilities = array(&lt;br /&gt;
        &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039; =&amp;gt; array(&lt;br /&gt;
            &#039;riskbitmask&#039; =&amp;gt; RISK_SPAM | RISK_PERSONAL | RISK_XSS | RISK_CONFIG,&lt;br /&gt;
            &#039;captype&#039; =&amp;gt; &#039;write&#039;,&lt;br /&gt;
            &#039;contextlevel&#039; =&amp;gt; CONTEXT_MODULE,&lt;br /&gt;
            &#039;legacy&#039; =&amp;gt; array(&lt;br /&gt;
                &#039;student&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;teacher&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;editingteacher&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;admin&#039; =&amp;gt; CAP_ALLOW&lt;br /&gt;
            )&lt;br /&gt;
        ),&lt;br /&gt;
    and you are supposed to iterate the array &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039; &lt;br /&gt;
    for each &amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt; you want to add&lt;br /&gt;
    following the same structure described before and, at the end,&lt;br /&gt;
    close the main array with&lt;br /&gt;
    )&lt;br /&gt;
&lt;br /&gt;
The element &#039;riskbitmask&#039; will be reflected in the list of icons of each row of the &#039;Override permissions&#039;-&amp;gt;roles page.&lt;br /&gt;
&lt;br /&gt;
You should add the right number of icon ranging from&lt;br /&gt;
    all four icons &lt;br /&gt;
        &#039;riskbitmask&#039; =&amp;gt; RISK_SPAM | RISK_PERSONAL | RISK_XSS | RISK_CONFIG,&lt;br /&gt;
    up to no icon at all,&lt;br /&gt;
        just removing the element &#039;riskbitmask&#039; from the array &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039;&lt;br /&gt;
&lt;br /&gt;
The element &#039;captype&#039; is ???&lt;br /&gt;
&lt;br /&gt;
The element &#039;contextlevel&#039; is ???&lt;br /&gt;
&lt;br /&gt;
The element &#039;legacy&#039; defines the legacy default for that permission. It is an array and for each element you are allowed to choose one (and only one) of these four elements: CAP_ALLOW, CAP_PREVENT, CAP_PROHIBIT, and inherit (if you don&#039;t set it). This defines the default selected radio button in the &#039;Legacy roles&#039; page.&lt;br /&gt;
&lt;br /&gt;
== Change the version number of your &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt; ==&lt;br /&gt;
Just change the version number of your &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt; by editing the file mod/version.php. Of course, you have to change it with a bigger one. :-)&lt;br /&gt;
&lt;br /&gt;
==Visit the &amp;quot;notification page&amp;quot; of the Site Administration block==&lt;br /&gt;
&lt;br /&gt;
And follow the instruction on the monitor.&lt;br /&gt;
&lt;br /&gt;
==Add to your code the right triggger==&lt;br /&gt;
&lt;br /&gt;
Add to your code something like:&lt;br /&gt;
&lt;br /&gt;
    if (has_capability(&#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039;, $context)) {&lt;br /&gt;
&lt;br /&gt;
In order to let it works, just add before it the definition of the $context variable&lt;br /&gt;
&lt;br /&gt;
    global $COURSE;&lt;br /&gt;
    if (! $cm = get_record(&amp;quot;course_modules&amp;quot;, &amp;quot;id&amp;quot;, $COURSE-&amp;gt;id)) {&lt;br /&gt;
        error(&amp;quot;Course Module ID was incorrect&amp;quot;);&lt;br /&gt;
    }&lt;br /&gt;
    $context = get_context_instance(CONTEXT_MODULE, $cm-&amp;gt;id);&lt;/div&gt;</summary>
		<author><name>Daniss</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Adding_capabilities&amp;diff=34669</id>
		<title>Development:NEWMODULE Adding capabilities</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Adding_capabilities&amp;diff=34669"/>
		<updated>2008-04-07T16:21:10Z</updated>

		<summary type="html">&lt;p&gt;Daniss: /* Add to your code the right triggger */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;In order to add a capabilities your &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt; you have to:&lt;br /&gt;
&lt;br /&gt;
==Create one access.php file in the &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;/db directory.==&lt;br /&gt;
&lt;br /&gt;
It must contain&lt;br /&gt;
*the capabilities to be installed and&lt;br /&gt;
*the defaults for each standard role.&lt;br /&gt;
&lt;br /&gt;
A model of what has to be added is: &lt;br /&gt;
    $mod_glossary_capabilities = array(&lt;br /&gt;
        &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039; =&amp;gt; array(&lt;br /&gt;
            &#039;riskbitmask&#039; =&amp;gt; RISK_SPAM | RISK_PERSONAL | RISK_XSS | RISK_CONFIG,&lt;br /&gt;
            &#039;captype&#039; =&amp;gt; &#039;write&#039;,&lt;br /&gt;
            &#039;contextlevel&#039; =&amp;gt; CONTEXT_MODULE,&lt;br /&gt;
            &#039;legacy&#039; =&amp;gt; array(&lt;br /&gt;
                &#039;student&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;teacher&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;editingteacher&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;admin&#039; =&amp;gt; CAP_ALLOW&lt;br /&gt;
            )&lt;br /&gt;
        ),&lt;br /&gt;
    and you are supposed to iterate the array &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039; &lt;br /&gt;
    for each &amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt; you want to add&lt;br /&gt;
    following the same structure described before and, at the end,&lt;br /&gt;
    close the main array with&lt;br /&gt;
    )&lt;br /&gt;
&lt;br /&gt;
The element &#039;riskbitmask&#039; will be reflected in the list of icons of each row of the &#039;Override permissions&#039;-&amp;gt;roles page.&lt;br /&gt;
&lt;br /&gt;
You should add the right number of icon ranging from&lt;br /&gt;
    all four icons &lt;br /&gt;
        &#039;riskbitmask&#039; =&amp;gt; RISK_SPAM | RISK_PERSONAL | RISK_XSS | RISK_CONFIG,&lt;br /&gt;
    up to no icon at all,&lt;br /&gt;
        just removing the element &#039;riskbitmask&#039; from the array &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039;&lt;br /&gt;
&lt;br /&gt;
The element &#039;captype&#039; is ???&lt;br /&gt;
&lt;br /&gt;
The element &#039;contextlevel&#039; is ???&lt;br /&gt;
&lt;br /&gt;
The element &#039;legacy&#039; defines the legacy default for that permission. It is an array and for each each element you are allowed to choose one (and only one) of these four elements: CAP_ALLOW, CAP_PREVENT, CAP_PROHIBIT, and inherit (if you don&#039;t set it). This defines the default selected radio button in the &#039;Legacy roles&#039; page.&lt;br /&gt;
&lt;br /&gt;
== Change the version number of your &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt; ==&lt;br /&gt;
Just change the version number of your &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt; by editing the file mod/version.php. Of course, you have to change it with a bigger one. :-)&lt;br /&gt;
&lt;br /&gt;
==Visit the &amp;quot;notification page&amp;quot; of the Site Administration block==&lt;br /&gt;
&lt;br /&gt;
And follow the instruction on the monitor.&lt;br /&gt;
&lt;br /&gt;
==Add to your code the right triggger==&lt;br /&gt;
&lt;br /&gt;
Add to your code something like:&lt;br /&gt;
&lt;br /&gt;
    if (has_capability(&#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039;, $context)) {&lt;br /&gt;
&lt;br /&gt;
In order to let it works, just add before it the definition of the $context variable&lt;br /&gt;
&lt;br /&gt;
    global $COURSE;&lt;br /&gt;
    if (! $cm = get_record(&amp;quot;course_modules&amp;quot;, &amp;quot;id&amp;quot;, $COURSE-&amp;gt;id)) {&lt;br /&gt;
        error(&amp;quot;Course Module ID was incorrect&amp;quot;);&lt;br /&gt;
    }&lt;br /&gt;
    $context = get_context_instance(CONTEXT_MODULE, $cm-&amp;gt;id);&lt;/div&gt;</summary>
		<author><name>Daniss</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Adding_capabilities&amp;diff=34668</id>
		<title>Development:NEWMODULE Adding capabilities</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Adding_capabilities&amp;diff=34668"/>
		<updated>2008-04-07T16:19:04Z</updated>

		<summary type="html">&lt;p&gt;Daniss: /* Add to your code the right triggger */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;In order to add a capabilities your &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt; you have to:&lt;br /&gt;
&lt;br /&gt;
==Create one access.php file in the &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;/db directory.==&lt;br /&gt;
&lt;br /&gt;
It must contain&lt;br /&gt;
*the capabilities to be installed and&lt;br /&gt;
*the defaults for each standard role.&lt;br /&gt;
&lt;br /&gt;
A model of what has to be added is: &lt;br /&gt;
    $mod_glossary_capabilities = array(&lt;br /&gt;
        &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039; =&amp;gt; array(&lt;br /&gt;
            &#039;riskbitmask&#039; =&amp;gt; RISK_SPAM | RISK_PERSONAL | RISK_XSS | RISK_CONFIG,&lt;br /&gt;
            &#039;captype&#039; =&amp;gt; &#039;write&#039;,&lt;br /&gt;
            &#039;contextlevel&#039; =&amp;gt; CONTEXT_MODULE,&lt;br /&gt;
            &#039;legacy&#039; =&amp;gt; array(&lt;br /&gt;
                &#039;student&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;teacher&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;editingteacher&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;admin&#039; =&amp;gt; CAP_ALLOW&lt;br /&gt;
            )&lt;br /&gt;
        ),&lt;br /&gt;
    and you are supposed to iterate the array &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039; &lt;br /&gt;
    for each &amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt; you want to add&lt;br /&gt;
    following the same structure described before and, at the end,&lt;br /&gt;
    close the main array with&lt;br /&gt;
    )&lt;br /&gt;
&lt;br /&gt;
The element &#039;riskbitmask&#039; will be reflected in the list of icons of each row of the &#039;Override permissions&#039;-&amp;gt;roles page.&lt;br /&gt;
&lt;br /&gt;
You should add the right number of icon ranging from&lt;br /&gt;
    all four icons &lt;br /&gt;
        &#039;riskbitmask&#039; =&amp;gt; RISK_SPAM | RISK_PERSONAL | RISK_XSS | RISK_CONFIG,&lt;br /&gt;
    up to no icon at all,&lt;br /&gt;
        just removing the element &#039;riskbitmask&#039; from the array &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039;&lt;br /&gt;
&lt;br /&gt;
The element &#039;captype&#039; is ???&lt;br /&gt;
&lt;br /&gt;
The element &#039;contextlevel&#039; is ???&lt;br /&gt;
&lt;br /&gt;
The element &#039;legacy&#039; defines the legacy default for that permission. It is an array and for each each element you are allowed to choose one (and only one) of these four elements: CAP_ALLOW, CAP_PREVENT, CAP_PROHIBIT, and inherit (if you don&#039;t set it). This defines the default selected radio button in the &#039;Legacy roles&#039; page.&lt;br /&gt;
&lt;br /&gt;
== Change the version number of your &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt; ==&lt;br /&gt;
Just change the version number of your &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt; by editing the file mod/version.php. Of course, you have to change it with a bigger one. :-)&lt;br /&gt;
&lt;br /&gt;
==Visit the &amp;quot;notification page&amp;quot; of the Site Administration block==&lt;br /&gt;
&lt;br /&gt;
And follow the instruction on the monitor.&lt;br /&gt;
&lt;br /&gt;
==Add to your code the right triggger==&lt;br /&gt;
&lt;br /&gt;
Add to your code something like:&lt;br /&gt;
&lt;br /&gt;
    if (has_capability(&#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039;, $context)) {&lt;br /&gt;
&lt;br /&gt;
In order to let it works, just add before it define the $context variable&lt;br /&gt;
&lt;br /&gt;
    global $COURSE;&lt;br /&gt;
    if (! $cm = get_record(&amp;quot;course_modules&amp;quot;, &amp;quot;id&amp;quot;, $COURSE-&amp;gt;id)) {&lt;br /&gt;
        error(&amp;quot;Course Module ID was incorrect&amp;quot;);&lt;br /&gt;
    }&lt;br /&gt;
    $context = get_context_instance(CONTEXT_MODULE, $cm-&amp;gt;id);&lt;/div&gt;</summary>
		<author><name>Daniss</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Adding_capabilities&amp;diff=34667</id>
		<title>Development:NEWMODULE Adding capabilities</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Adding_capabilities&amp;diff=34667"/>
		<updated>2008-04-07T16:18:37Z</updated>

		<summary type="html">&lt;p&gt;Daniss: /* Visit the &amp;quot;notification page&amp;quot; of the Site Administration block */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;In order to add a capabilities your &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt; you have to:&lt;br /&gt;
&lt;br /&gt;
==Create one access.php file in the &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;/db directory.==&lt;br /&gt;
&lt;br /&gt;
It must contain&lt;br /&gt;
*the capabilities to be installed and&lt;br /&gt;
*the defaults for each standard role.&lt;br /&gt;
&lt;br /&gt;
A model of what has to be added is: &lt;br /&gt;
    $mod_glossary_capabilities = array(&lt;br /&gt;
        &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039; =&amp;gt; array(&lt;br /&gt;
            &#039;riskbitmask&#039; =&amp;gt; RISK_SPAM | RISK_PERSONAL | RISK_XSS | RISK_CONFIG,&lt;br /&gt;
            &#039;captype&#039; =&amp;gt; &#039;write&#039;,&lt;br /&gt;
            &#039;contextlevel&#039; =&amp;gt; CONTEXT_MODULE,&lt;br /&gt;
            &#039;legacy&#039; =&amp;gt; array(&lt;br /&gt;
                &#039;student&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;teacher&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;editingteacher&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;admin&#039; =&amp;gt; CAP_ALLOW&lt;br /&gt;
            )&lt;br /&gt;
        ),&lt;br /&gt;
    and you are supposed to iterate the array &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039; &lt;br /&gt;
    for each &amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt; you want to add&lt;br /&gt;
    following the same structure described before and, at the end,&lt;br /&gt;
    close the main array with&lt;br /&gt;
    )&lt;br /&gt;
&lt;br /&gt;
The element &#039;riskbitmask&#039; will be reflected in the list of icons of each row of the &#039;Override permissions&#039;-&amp;gt;roles page.&lt;br /&gt;
&lt;br /&gt;
You should add the right number of icon ranging from&lt;br /&gt;
    all four icons &lt;br /&gt;
        &#039;riskbitmask&#039; =&amp;gt; RISK_SPAM | RISK_PERSONAL | RISK_XSS | RISK_CONFIG,&lt;br /&gt;
    up to no icon at all,&lt;br /&gt;
        just removing the element &#039;riskbitmask&#039; from the array &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039;&lt;br /&gt;
&lt;br /&gt;
The element &#039;captype&#039; is ???&lt;br /&gt;
&lt;br /&gt;
The element &#039;contextlevel&#039; is ???&lt;br /&gt;
&lt;br /&gt;
The element &#039;legacy&#039; defines the legacy default for that permission. It is an array and for each each element you are allowed to choose one (and only one) of these four elements: CAP_ALLOW, CAP_PREVENT, CAP_PROHIBIT, and inherit (if you don&#039;t set it). This defines the default selected radio button in the &#039;Legacy roles&#039; page.&lt;br /&gt;
&lt;br /&gt;
== Change the version number of your &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt; ==&lt;br /&gt;
Just change the version number of your &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt; by editing the file mod/version.php. Of course, you have to change it with a bigger one. :-)&lt;br /&gt;
&lt;br /&gt;
==Visit the &amp;quot;notification page&amp;quot; of the Site Administration block==&lt;br /&gt;
&lt;br /&gt;
And follow the instruction on the monitor.&lt;br /&gt;
&lt;br /&gt;
==Add to your code the right triggger==&lt;br /&gt;
&lt;br /&gt;
Add to your code something like:&lt;br /&gt;
&lt;br /&gt;
    if (has_capability(&#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039;, $context)) {&lt;br /&gt;
&lt;br /&gt;
In order to let it works, just add before it define the variable $context&lt;br /&gt;
&lt;br /&gt;
    global $COURSE;&lt;br /&gt;
    if (! $cm = get_record(&amp;quot;course_modules&amp;quot;, &amp;quot;id&amp;quot;, $COURSE-&amp;gt;id)) {&lt;br /&gt;
        error(&amp;quot;Course Module ID was incorrect&amp;quot;);&lt;br /&gt;
    }&lt;br /&gt;
    $context = get_context_instance(CONTEXT_MODULE, $cm-&amp;gt;id);&lt;/div&gt;</summary>
		<author><name>Daniss</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Adding_capabilities&amp;diff=34663</id>
		<title>Development:NEWMODULE Adding capabilities</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Adding_capabilities&amp;diff=34663"/>
		<updated>2008-04-07T14:42:33Z</updated>

		<summary type="html">&lt;p&gt;Daniss: /* Add to your code the right triggger */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;In order to add a capabilities your &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt; you have to:&lt;br /&gt;
&lt;br /&gt;
==Create one access.php file in the &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;/db directory.==&lt;br /&gt;
&lt;br /&gt;
It must contain&lt;br /&gt;
*the capabilities to be installed and&lt;br /&gt;
*the defaults for each standard role.&lt;br /&gt;
&lt;br /&gt;
A model of what has to be added is: &lt;br /&gt;
    $mod_glossary_capabilities = array(&lt;br /&gt;
        &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039; =&amp;gt; array(&lt;br /&gt;
            &#039;riskbitmask&#039; =&amp;gt; RISK_SPAM | RISK_PERSONAL | RISK_XSS | RISK_CONFIG,&lt;br /&gt;
            &#039;captype&#039; =&amp;gt; &#039;write&#039;,&lt;br /&gt;
            &#039;contextlevel&#039; =&amp;gt; CONTEXT_MODULE,&lt;br /&gt;
            &#039;legacy&#039; =&amp;gt; array(&lt;br /&gt;
                &#039;student&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;teacher&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;editingteacher&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;admin&#039; =&amp;gt; CAP_ALLOW&lt;br /&gt;
            )&lt;br /&gt;
        ),&lt;br /&gt;
    and you are supposed to iterate the array &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039; &lt;br /&gt;
    for each &amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt; you want to add&lt;br /&gt;
    following the same structure described before and, at the end,&lt;br /&gt;
    close the main array with&lt;br /&gt;
    )&lt;br /&gt;
&lt;br /&gt;
The element &#039;riskbitmask&#039; will be reflected in the list of icons of each row of the &#039;Override permissions&#039;-&amp;gt;roles page.&lt;br /&gt;
&lt;br /&gt;
You should add the right number of icon ranging from&lt;br /&gt;
    all four icons &lt;br /&gt;
        &#039;riskbitmask&#039; =&amp;gt; RISK_SPAM | RISK_PERSONAL | RISK_XSS | RISK_CONFIG,&lt;br /&gt;
    up to no icon at all,&lt;br /&gt;
        just removing the element &#039;riskbitmask&#039; from the array &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039;&lt;br /&gt;
&lt;br /&gt;
The element &#039;captype&#039; is ???&lt;br /&gt;
&lt;br /&gt;
The element &#039;contextlevel&#039; is ???&lt;br /&gt;
&lt;br /&gt;
The element &#039;legacy&#039; defines the legacy default for that permission. It is an array and for each each element you are allowed to choose one (and only one) of these four elements: CAP_ALLOW, CAP_PREVENT, CAP_PROHIBIT, and inherit (if you don&#039;t set it). This defines the default selected radio button in the &#039;Legacy roles&#039; page.&lt;br /&gt;
&lt;br /&gt;
== Change the version number of your &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt; ==&lt;br /&gt;
Just change the version number of your &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt; by editing the file mod/version.php. Of course, you have to change it with a bigger one. :-)&lt;br /&gt;
&lt;br /&gt;
==Visit the &amp;quot;notification page&amp;quot; of the Site Administration block==&lt;br /&gt;
&lt;br /&gt;
==Add to your code the right triggger==&lt;br /&gt;
&lt;br /&gt;
Add to your code something like:&lt;br /&gt;
&lt;br /&gt;
    if (has_capability(&#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039;, $context)) {&lt;br /&gt;
&lt;br /&gt;
In order to let it works, just add before it define the variable $context&lt;br /&gt;
&lt;br /&gt;
    global $COURSE;&lt;br /&gt;
    if (! $cm = get_record(&amp;quot;course_modules&amp;quot;, &amp;quot;id&amp;quot;, $COURSE-&amp;gt;id)) {&lt;br /&gt;
        error(&amp;quot;Course Module ID was incorrect&amp;quot;);&lt;br /&gt;
    }&lt;br /&gt;
    $context = get_context_instance(CONTEXT_MODULE, $cm-&amp;gt;id);&lt;/div&gt;</summary>
		<author><name>Daniss</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Adding_capabilities&amp;diff=34662</id>
		<title>Development:NEWMODULE Adding capabilities</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Adding_capabilities&amp;diff=34662"/>
		<updated>2008-04-07T14:40:49Z</updated>

		<summary type="html">&lt;p&gt;Daniss: /* Change the version number of your &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt; */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;In order to add a capabilities your &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt; you have to:&lt;br /&gt;
&lt;br /&gt;
==Create one access.php file in the &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;/db directory.==&lt;br /&gt;
&lt;br /&gt;
It must contain&lt;br /&gt;
*the capabilities to be installed and&lt;br /&gt;
*the defaults for each standard role.&lt;br /&gt;
&lt;br /&gt;
A model of what has to be added is: &lt;br /&gt;
    $mod_glossary_capabilities = array(&lt;br /&gt;
        &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039; =&amp;gt; array(&lt;br /&gt;
            &#039;riskbitmask&#039; =&amp;gt; RISK_SPAM | RISK_PERSONAL | RISK_XSS | RISK_CONFIG,&lt;br /&gt;
            &#039;captype&#039; =&amp;gt; &#039;write&#039;,&lt;br /&gt;
            &#039;contextlevel&#039; =&amp;gt; CONTEXT_MODULE,&lt;br /&gt;
            &#039;legacy&#039; =&amp;gt; array(&lt;br /&gt;
                &#039;student&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;teacher&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;editingteacher&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;admin&#039; =&amp;gt; CAP_ALLOW&lt;br /&gt;
            )&lt;br /&gt;
        ),&lt;br /&gt;
    and you are supposed to iterate the array &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039; &lt;br /&gt;
    for each &amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt; you want to add&lt;br /&gt;
    following the same structure described before and, at the end,&lt;br /&gt;
    close the main array with&lt;br /&gt;
    )&lt;br /&gt;
&lt;br /&gt;
The element &#039;riskbitmask&#039; will be reflected in the list of icons of each row of the &#039;Override permissions&#039;-&amp;gt;roles page.&lt;br /&gt;
&lt;br /&gt;
You should add the right number of icon ranging from&lt;br /&gt;
    all four icons &lt;br /&gt;
        &#039;riskbitmask&#039; =&amp;gt; RISK_SPAM | RISK_PERSONAL | RISK_XSS | RISK_CONFIG,&lt;br /&gt;
    up to no icon at all,&lt;br /&gt;
        just removing the element &#039;riskbitmask&#039; from the array &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039;&lt;br /&gt;
&lt;br /&gt;
The element &#039;captype&#039; is ???&lt;br /&gt;
&lt;br /&gt;
The element &#039;contextlevel&#039; is ???&lt;br /&gt;
&lt;br /&gt;
The element &#039;legacy&#039; defines the legacy default for that permission. It is an array and for each each element you are allowed to choose one (and only one) of these four elements: CAP_ALLOW, CAP_PREVENT, CAP_PROHIBIT, and inherit (if you don&#039;t set it). This defines the default selected radio button in the &#039;Legacy roles&#039; page.&lt;br /&gt;
&lt;br /&gt;
== Change the version number of your &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt; ==&lt;br /&gt;
Just change the version number of your &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt; by editing the file mod/version.php. Of course, you have to change it with a bigger one. :-)&lt;br /&gt;
&lt;br /&gt;
==Visit the &amp;quot;notification page&amp;quot; of the Site Administration block==&lt;br /&gt;
&lt;br /&gt;
==Add to your code the right triggger==&lt;br /&gt;
&lt;br /&gt;
Add to your code something like:&lt;br /&gt;
&lt;br /&gt;
        if (has_capability(&#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039;, $context)) {&lt;br /&gt;
&lt;br /&gt;
In order to let it works, just add before it define the variable $context&lt;br /&gt;
&lt;br /&gt;
        global $COURSE;&lt;br /&gt;
        if (! $cm = get_record(&amp;quot;course_modules&amp;quot;, &amp;quot;id&amp;quot;, $COURSE-&amp;gt;id)) {&lt;br /&gt;
            error(&amp;quot;Course Module ID was incorrect&amp;quot;);&lt;br /&gt;
        }&lt;br /&gt;
        $context = get_context_instance(CONTEXT_MODULE, $cm-&amp;gt;id);&lt;/div&gt;</summary>
		<author><name>Daniss</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Adding_capabilities&amp;diff=34661</id>
		<title>Development:NEWMODULE Adding capabilities</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Adding_capabilities&amp;diff=34661"/>
		<updated>2008-04-07T14:40:26Z</updated>

		<summary type="html">&lt;p&gt;Daniss: /* Add to your code the right triggger */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;In order to add a capabilities your &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt; you have to:&lt;br /&gt;
&lt;br /&gt;
==Create one access.php file in the &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;/db directory.==&lt;br /&gt;
&lt;br /&gt;
It must contain&lt;br /&gt;
*the capabilities to be installed and&lt;br /&gt;
*the defaults for each standard role.&lt;br /&gt;
&lt;br /&gt;
A model of what has to be added is: &lt;br /&gt;
    $mod_glossary_capabilities = array(&lt;br /&gt;
        &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039; =&amp;gt; array(&lt;br /&gt;
            &#039;riskbitmask&#039; =&amp;gt; RISK_SPAM | RISK_PERSONAL | RISK_XSS | RISK_CONFIG,&lt;br /&gt;
            &#039;captype&#039; =&amp;gt; &#039;write&#039;,&lt;br /&gt;
            &#039;contextlevel&#039; =&amp;gt; CONTEXT_MODULE,&lt;br /&gt;
            &#039;legacy&#039; =&amp;gt; array(&lt;br /&gt;
                &#039;student&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;teacher&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;editingteacher&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;admin&#039; =&amp;gt; CAP_ALLOW&lt;br /&gt;
            )&lt;br /&gt;
        ),&lt;br /&gt;
    and you are supposed to iterate the array &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039; &lt;br /&gt;
    for each &amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt; you want to add&lt;br /&gt;
    following the same structure described before and, at the end,&lt;br /&gt;
    close the main array with&lt;br /&gt;
    )&lt;br /&gt;
&lt;br /&gt;
The element &#039;riskbitmask&#039; will be reflected in the list of icons of each row of the &#039;Override permissions&#039;-&amp;gt;roles page.&lt;br /&gt;
&lt;br /&gt;
You should add the right number of icon ranging from&lt;br /&gt;
    all four icons &lt;br /&gt;
        &#039;riskbitmask&#039; =&amp;gt; RISK_SPAM | RISK_PERSONAL | RISK_XSS | RISK_CONFIG,&lt;br /&gt;
    up to no icon at all,&lt;br /&gt;
        just removing the element &#039;riskbitmask&#039; from the array &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039;&lt;br /&gt;
&lt;br /&gt;
The element &#039;captype&#039; is ???&lt;br /&gt;
&lt;br /&gt;
The element &#039;contextlevel&#039; is ???&lt;br /&gt;
&lt;br /&gt;
The element &#039;legacy&#039; defines the legacy default for that permission. It is an array and for each each element you are allowed to choose one (and only one) of these four elements: CAP_ALLOW, CAP_PREVENT, CAP_PROHIBIT, and inherit (if you don&#039;t set it). This defines the default selected radio button in the &#039;Legacy roles&#039; page.&lt;br /&gt;
&lt;br /&gt;
== Change the version number of your &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt; ==&lt;br /&gt;
just chenge the version number of your &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt; by editing the file mod/version.php. Of vcourse, you have to change it with a bigger one. :-)&lt;br /&gt;
&lt;br /&gt;
==Visit the &amp;quot;notification page&amp;quot; of the Site Administration block==&lt;br /&gt;
&lt;br /&gt;
==Add to your code the right triggger==&lt;br /&gt;
&lt;br /&gt;
Add to your code something like:&lt;br /&gt;
&lt;br /&gt;
        if (has_capability(&#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039;, $context)) {&lt;br /&gt;
&lt;br /&gt;
In order to let it works, just add before it define the variable $context&lt;br /&gt;
&lt;br /&gt;
        global $COURSE;&lt;br /&gt;
        if (! $cm = get_record(&amp;quot;course_modules&amp;quot;, &amp;quot;id&amp;quot;, $COURSE-&amp;gt;id)) {&lt;br /&gt;
            error(&amp;quot;Course Module ID was incorrect&amp;quot;);&lt;br /&gt;
        }&lt;br /&gt;
        $context = get_context_instance(CONTEXT_MODULE, $cm-&amp;gt;id);&lt;/div&gt;</summary>
		<author><name>Daniss</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Adding_capabilities&amp;diff=34660</id>
		<title>Development:NEWMODULE Adding capabilities</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Adding_capabilities&amp;diff=34660"/>
		<updated>2008-04-07T14:37:07Z</updated>

		<summary type="html">&lt;p&gt;Daniss: /* Add to your code the right triggger */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;In order to add a capabilities your &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt; you have to:&lt;br /&gt;
&lt;br /&gt;
==Create one access.php file in the &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;/db directory.==&lt;br /&gt;
&lt;br /&gt;
It must contain&lt;br /&gt;
*the capabilities to be installed and&lt;br /&gt;
*the defaults for each standard role.&lt;br /&gt;
&lt;br /&gt;
A model of what has to be added is: &lt;br /&gt;
    $mod_glossary_capabilities = array(&lt;br /&gt;
        &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039; =&amp;gt; array(&lt;br /&gt;
            &#039;riskbitmask&#039; =&amp;gt; RISK_SPAM | RISK_PERSONAL | RISK_XSS | RISK_CONFIG,&lt;br /&gt;
            &#039;captype&#039; =&amp;gt; &#039;write&#039;,&lt;br /&gt;
            &#039;contextlevel&#039; =&amp;gt; CONTEXT_MODULE,&lt;br /&gt;
            &#039;legacy&#039; =&amp;gt; array(&lt;br /&gt;
                &#039;student&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;teacher&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;editingteacher&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;admin&#039; =&amp;gt; CAP_ALLOW&lt;br /&gt;
            )&lt;br /&gt;
        ),&lt;br /&gt;
    and you are supposed to iterate the array &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039; &lt;br /&gt;
    for each &amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt; you want to add&lt;br /&gt;
    following the same structure described before and, at the end,&lt;br /&gt;
    close the main array with&lt;br /&gt;
    )&lt;br /&gt;
&lt;br /&gt;
The element &#039;riskbitmask&#039; will be reflected in the list of icons of each row of the &#039;Override permissions&#039;-&amp;gt;roles page.&lt;br /&gt;
&lt;br /&gt;
You should add the right number of icon ranging from&lt;br /&gt;
    all four icons &lt;br /&gt;
        &#039;riskbitmask&#039; =&amp;gt; RISK_SPAM | RISK_PERSONAL | RISK_XSS | RISK_CONFIG,&lt;br /&gt;
    up to no icon at all,&lt;br /&gt;
        just removing the element &#039;riskbitmask&#039; from the array &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039;&lt;br /&gt;
&lt;br /&gt;
The element &#039;captype&#039; is ???&lt;br /&gt;
&lt;br /&gt;
The element &#039;contextlevel&#039; is ???&lt;br /&gt;
&lt;br /&gt;
The element &#039;legacy&#039; defines the legacy default for that permission. It is an array and for each each element you are allowed to choose one (and only one) of these four elements: CAP_ALLOW, CAP_PREVENT, CAP_PROHIBIT, and inherit (if you don&#039;t set it). This defines the default selected radio button in the &#039;Legacy roles&#039; page.&lt;br /&gt;
&lt;br /&gt;
== Change the version number of your &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt; ==&lt;br /&gt;
just chenge the version number of your &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt; by editing the file mod/version.php. Of vcourse, you have to change it with a bigger one. :-)&lt;br /&gt;
&lt;br /&gt;
==Visit the &amp;quot;notification page&amp;quot; of the Site Administration block==&lt;br /&gt;
&lt;br /&gt;
==Add to your code the right triggger==&lt;br /&gt;
&lt;br /&gt;
Add to your code something like:&lt;br /&gt;
&lt;br /&gt;
        if (has_capability(&#039;mod/support:confirm&#039;, $context)) {&lt;br /&gt;
&lt;br /&gt;
In order to let it works, just add before it define the variable $context&lt;br /&gt;
&lt;br /&gt;
        global $COURSE;&lt;br /&gt;
        if (! $cm = get_record(&amp;quot;course_modules&amp;quot;, &amp;quot;id&amp;quot;, $COURSE-&amp;gt;id)) {&lt;br /&gt;
            error(&amp;quot;Course Module ID was incorrect&amp;quot;);&lt;br /&gt;
        }&lt;br /&gt;
        $context = get_context_instance(CONTEXT_MODULE, $cm-&amp;gt;id);&lt;/div&gt;</summary>
		<author><name>Daniss</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Adding_capabilities&amp;diff=34659</id>
		<title>Development:NEWMODULE Adding capabilities</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Adding_capabilities&amp;diff=34659"/>
		<updated>2008-04-07T14:36:31Z</updated>

		<summary type="html">&lt;p&gt;Daniss: /* Add to your code the right triggger */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;In order to add a capabilities your &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt; you have to:&lt;br /&gt;
&lt;br /&gt;
==Create one access.php file in the &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;/db directory.==&lt;br /&gt;
&lt;br /&gt;
It must contain&lt;br /&gt;
*the capabilities to be installed and&lt;br /&gt;
*the defaults for each standard role.&lt;br /&gt;
&lt;br /&gt;
A model of what has to be added is: &lt;br /&gt;
    $mod_glossary_capabilities = array(&lt;br /&gt;
        &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039; =&amp;gt; array(&lt;br /&gt;
            &#039;riskbitmask&#039; =&amp;gt; RISK_SPAM | RISK_PERSONAL | RISK_XSS | RISK_CONFIG,&lt;br /&gt;
            &#039;captype&#039; =&amp;gt; &#039;write&#039;,&lt;br /&gt;
            &#039;contextlevel&#039; =&amp;gt; CONTEXT_MODULE,&lt;br /&gt;
            &#039;legacy&#039; =&amp;gt; array(&lt;br /&gt;
                &#039;student&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;teacher&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;editingteacher&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;admin&#039; =&amp;gt; CAP_ALLOW&lt;br /&gt;
            )&lt;br /&gt;
        ),&lt;br /&gt;
    and you are supposed to iterate the array &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039; &lt;br /&gt;
    for each &amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt; you want to add&lt;br /&gt;
    following the same structure described before and, at the end,&lt;br /&gt;
    close the main array with&lt;br /&gt;
    )&lt;br /&gt;
&lt;br /&gt;
The element &#039;riskbitmask&#039; will be reflected in the list of icons of each row of the &#039;Override permissions&#039;-&amp;gt;roles page.&lt;br /&gt;
&lt;br /&gt;
You should add the right number of icon ranging from&lt;br /&gt;
    all four icons &lt;br /&gt;
        &#039;riskbitmask&#039; =&amp;gt; RISK_SPAM | RISK_PERSONAL | RISK_XSS | RISK_CONFIG,&lt;br /&gt;
    up to no icon at all,&lt;br /&gt;
        just removing the element &#039;riskbitmask&#039; from the array &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039;&lt;br /&gt;
&lt;br /&gt;
The element &#039;captype&#039; is ???&lt;br /&gt;
&lt;br /&gt;
The element &#039;contextlevel&#039; is ???&lt;br /&gt;
&lt;br /&gt;
The element &#039;legacy&#039; defines the legacy default for that permission. It is an array and for each each element you are allowed to choose one (and only one) of these four elements: CAP_ALLOW, CAP_PREVENT, CAP_PROHIBIT, and inherit (if you don&#039;t set it). This defines the default selected radio button in the &#039;Legacy roles&#039; page.&lt;br /&gt;
&lt;br /&gt;
== Change the version number of your &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt; ==&lt;br /&gt;
just chenge the version number of your &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt; by editing the file mod/version.php. Of vcourse, you have to change it with a bigger one. :-)&lt;br /&gt;
&lt;br /&gt;
==Visit the &amp;quot;notification page&amp;quot; of the Site Administration block==&lt;br /&gt;
&lt;br /&gt;
==Add to your code the right triggger==&lt;br /&gt;
&lt;br /&gt;
Add to your code something like:&lt;br /&gt;
&lt;br /&gt;
        if (has_capability(&#039;mod/support:confirm&#039;, $context)) {&lt;br /&gt;
&lt;br /&gt;
In order to let it works, just add before it define the variable $context&lt;br /&gt;
&lt;br /&gt;
        if (! $cm = get_record(&amp;quot;course_modules&amp;quot;, &amp;quot;id&amp;quot;, $COURSE-&amp;gt;id)) {&lt;br /&gt;
            error(&amp;quot;Course Module ID was incorrect&amp;quot;);&lt;br /&gt;
        }&lt;br /&gt;
        $context = get_context_instance(CONTEXT_MODULE, $cm-&amp;gt;id);&lt;/div&gt;</summary>
		<author><name>Daniss</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Adding_capabilities&amp;diff=34657</id>
		<title>Development:NEWMODULE Adding capabilities</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Adding_capabilities&amp;diff=34657"/>
		<updated>2008-04-07T14:33:51Z</updated>

		<summary type="html">&lt;p&gt;Daniss: /* Visit the &amp;quot;notification page&amp;quot; of the Admin block */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;In order to add a capabilities your &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt; you have to:&lt;br /&gt;
&lt;br /&gt;
==Create one access.php file in the &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;/db directory.==&lt;br /&gt;
&lt;br /&gt;
It must contain&lt;br /&gt;
*the capabilities to be installed and&lt;br /&gt;
*the defaults for each standard role.&lt;br /&gt;
&lt;br /&gt;
A model of what has to be added is: &lt;br /&gt;
    $mod_glossary_capabilities = array(&lt;br /&gt;
        &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039; =&amp;gt; array(&lt;br /&gt;
            &#039;riskbitmask&#039; =&amp;gt; RISK_SPAM | RISK_PERSONAL | RISK_XSS | RISK_CONFIG,&lt;br /&gt;
            &#039;captype&#039; =&amp;gt; &#039;write&#039;,&lt;br /&gt;
            &#039;contextlevel&#039; =&amp;gt; CONTEXT_MODULE,&lt;br /&gt;
            &#039;legacy&#039; =&amp;gt; array(&lt;br /&gt;
                &#039;student&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;teacher&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;editingteacher&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;admin&#039; =&amp;gt; CAP_ALLOW&lt;br /&gt;
            )&lt;br /&gt;
        ),&lt;br /&gt;
    and you are supposed to iterate the array &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039; &lt;br /&gt;
    for each &amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt; you want to add&lt;br /&gt;
    following the same structure described before and, at the end,&lt;br /&gt;
    close the main array with&lt;br /&gt;
    )&lt;br /&gt;
&lt;br /&gt;
The element &#039;riskbitmask&#039; will be reflected in the list of icons of each row of the &#039;Override permissions&#039;-&amp;gt;roles page.&lt;br /&gt;
&lt;br /&gt;
You should add the right number of icon ranging from&lt;br /&gt;
    all four icons &lt;br /&gt;
        &#039;riskbitmask&#039; =&amp;gt; RISK_SPAM | RISK_PERSONAL | RISK_XSS | RISK_CONFIG,&lt;br /&gt;
    up to no icon at all,&lt;br /&gt;
        just removing the element &#039;riskbitmask&#039; from the array &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039;&lt;br /&gt;
&lt;br /&gt;
The element &#039;captype&#039; is ???&lt;br /&gt;
&lt;br /&gt;
The element &#039;contextlevel&#039; is ???&lt;br /&gt;
&lt;br /&gt;
The element &#039;legacy&#039; defines the legacy default for that permission. It is an array and for each each element you are allowed to choose one (and only one) of these four elements: CAP_ALLOW, CAP_PREVENT, CAP_PROHIBIT, and inherit (if you don&#039;t set it). This defines the default selected radio button in the &#039;Legacy roles&#039; page.&lt;br /&gt;
&lt;br /&gt;
== Change the version number of your &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt; ==&lt;br /&gt;
just chenge the version number of your &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt; by editing the file mod/version.php. Of vcourse, you have to change it with a bigger one. :-)&lt;br /&gt;
&lt;br /&gt;
==Visit the &amp;quot;notification page&amp;quot; of the Site Administration block==&lt;br /&gt;
&lt;br /&gt;
==Add to your code the right triggger==&lt;/div&gt;</summary>
		<author><name>Daniss</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Adding_capabilities&amp;diff=34656</id>
		<title>Development:NEWMODULE Adding capabilities</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Adding_capabilities&amp;diff=34656"/>
		<updated>2008-04-07T14:33:21Z</updated>

		<summary type="html">&lt;p&gt;Daniss: /* Change the version number of your &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt; */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;In order to add a capabilities your &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt; you have to:&lt;br /&gt;
&lt;br /&gt;
==Create one access.php file in the &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;/db directory.==&lt;br /&gt;
&lt;br /&gt;
It must contain&lt;br /&gt;
*the capabilities to be installed and&lt;br /&gt;
*the defaults for each standard role.&lt;br /&gt;
&lt;br /&gt;
A model of what has to be added is: &lt;br /&gt;
    $mod_glossary_capabilities = array(&lt;br /&gt;
        &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039; =&amp;gt; array(&lt;br /&gt;
            &#039;riskbitmask&#039; =&amp;gt; RISK_SPAM | RISK_PERSONAL | RISK_XSS | RISK_CONFIG,&lt;br /&gt;
            &#039;captype&#039; =&amp;gt; &#039;write&#039;,&lt;br /&gt;
            &#039;contextlevel&#039; =&amp;gt; CONTEXT_MODULE,&lt;br /&gt;
            &#039;legacy&#039; =&amp;gt; array(&lt;br /&gt;
                &#039;student&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;teacher&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;editingteacher&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;admin&#039; =&amp;gt; CAP_ALLOW&lt;br /&gt;
            )&lt;br /&gt;
        ),&lt;br /&gt;
    and you are supposed to iterate the array &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039; &lt;br /&gt;
    for each &amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt; you want to add&lt;br /&gt;
    following the same structure described before and, at the end,&lt;br /&gt;
    close the main array with&lt;br /&gt;
    )&lt;br /&gt;
&lt;br /&gt;
The element &#039;riskbitmask&#039; will be reflected in the list of icons of each row of the &#039;Override permissions&#039;-&amp;gt;roles page.&lt;br /&gt;
&lt;br /&gt;
You should add the right number of icon ranging from&lt;br /&gt;
    all four icons &lt;br /&gt;
        &#039;riskbitmask&#039; =&amp;gt; RISK_SPAM | RISK_PERSONAL | RISK_XSS | RISK_CONFIG,&lt;br /&gt;
    up to no icon at all,&lt;br /&gt;
        just removing the element &#039;riskbitmask&#039; from the array &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039;&lt;br /&gt;
&lt;br /&gt;
The element &#039;captype&#039; is ???&lt;br /&gt;
&lt;br /&gt;
The element &#039;contextlevel&#039; is ???&lt;br /&gt;
&lt;br /&gt;
The element &#039;legacy&#039; defines the legacy default for that permission. It is an array and for each each element you are allowed to choose one (and only one) of these four elements: CAP_ALLOW, CAP_PREVENT, CAP_PROHIBIT, and inherit (if you don&#039;t set it). This defines the default selected radio button in the &#039;Legacy roles&#039; page.&lt;br /&gt;
&lt;br /&gt;
== Change the version number of your &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt; ==&lt;br /&gt;
just chenge the version number of your &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt; by editing the file mod/version.php. Of vcourse, you have to change it with a bigger one. :-)&lt;br /&gt;
&lt;br /&gt;
==Visit the &amp;quot;notification page&amp;quot; of the Admin block==&lt;br /&gt;
&lt;br /&gt;
==Add to your code the right triggger==&lt;/div&gt;</summary>
		<author><name>Daniss</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Adding_capabilities&amp;diff=34655</id>
		<title>Development:NEWMODULE Adding capabilities</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Adding_capabilities&amp;diff=34655"/>
		<updated>2008-04-07T14:30:58Z</updated>

		<summary type="html">&lt;p&gt;Daniss: /* Create one access.php file in the &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;/db directory. */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;In order to add a capabilities your &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt; you have to:&lt;br /&gt;
&lt;br /&gt;
==Create one access.php file in the &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;/db directory.==&lt;br /&gt;
&lt;br /&gt;
It must contain&lt;br /&gt;
*the capabilities to be installed and&lt;br /&gt;
*the defaults for each standard role.&lt;br /&gt;
&lt;br /&gt;
A model of what has to be added is: &lt;br /&gt;
    $mod_glossary_capabilities = array(&lt;br /&gt;
        &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039; =&amp;gt; array(&lt;br /&gt;
            &#039;riskbitmask&#039; =&amp;gt; RISK_SPAM | RISK_PERSONAL | RISK_XSS | RISK_CONFIG,&lt;br /&gt;
            &#039;captype&#039; =&amp;gt; &#039;write&#039;,&lt;br /&gt;
            &#039;contextlevel&#039; =&amp;gt; CONTEXT_MODULE,&lt;br /&gt;
            &#039;legacy&#039; =&amp;gt; array(&lt;br /&gt;
                &#039;student&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;teacher&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;editingteacher&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;admin&#039; =&amp;gt; CAP_ALLOW&lt;br /&gt;
            )&lt;br /&gt;
        ),&lt;br /&gt;
    and you are supposed to iterate the array &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039; &lt;br /&gt;
    for each &amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt; you want to add&lt;br /&gt;
    following the same structure described before and, at the end,&lt;br /&gt;
    close the main array with&lt;br /&gt;
    )&lt;br /&gt;
&lt;br /&gt;
The element &#039;riskbitmask&#039; will be reflected in the list of icons of each row of the &#039;Override permissions&#039;-&amp;gt;roles page.&lt;br /&gt;
&lt;br /&gt;
You should add the right number of icon ranging from&lt;br /&gt;
    all four icons &lt;br /&gt;
        &#039;riskbitmask&#039; =&amp;gt; RISK_SPAM | RISK_PERSONAL | RISK_XSS | RISK_CONFIG,&lt;br /&gt;
    up to no icon at all,&lt;br /&gt;
        just removing the element &#039;riskbitmask&#039; from the array &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039;&lt;br /&gt;
&lt;br /&gt;
The element &#039;captype&#039; is ???&lt;br /&gt;
&lt;br /&gt;
The element &#039;contextlevel&#039; is ???&lt;br /&gt;
&lt;br /&gt;
The element &#039;legacy&#039; defines the legacy default for that permission. It is an array and for each each element you are allowed to choose one (and only one) of these four elements: CAP_ALLOW, CAP_PREVENT, CAP_PROHIBIT, and inherit (if you don&#039;t set it). This defines the default selected radio button in the &#039;Legacy roles&#039; page.&lt;br /&gt;
&lt;br /&gt;
== Change the version number of your &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt; ==&lt;/div&gt;</summary>
		<author><name>Daniss</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Adding_capabilities&amp;diff=34654</id>
		<title>Development:NEWMODULE Adding capabilities</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Adding_capabilities&amp;diff=34654"/>
		<updated>2008-04-07T14:30:08Z</updated>

		<summary type="html">&lt;p&gt;Daniss: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Create one access.php file in the &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;/db directory.==&lt;br /&gt;
&lt;br /&gt;
It must contain&lt;br /&gt;
*the capabilities to be installed and&lt;br /&gt;
*the defaults for each standard role.&lt;br /&gt;
&lt;br /&gt;
A model of what has to be added is: &lt;br /&gt;
    $mod_glossary_capabilities = array(&lt;br /&gt;
        &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039; =&amp;gt; array(&lt;br /&gt;
            &#039;riskbitmask&#039; =&amp;gt; RISK_SPAM | RISK_PERSONAL | RISK_XSS | RISK_CONFIG,&lt;br /&gt;
            &#039;captype&#039; =&amp;gt; &#039;write&#039;,&lt;br /&gt;
            &#039;contextlevel&#039; =&amp;gt; CONTEXT_MODULE,&lt;br /&gt;
            &#039;legacy&#039; =&amp;gt; array(&lt;br /&gt;
                &#039;student&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;teacher&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;editingteacher&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;admin&#039; =&amp;gt; CAP_ALLOW&lt;br /&gt;
            )&lt;br /&gt;
        ),&lt;br /&gt;
    and you are supposed to iterate the array &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039; &lt;br /&gt;
    for each &amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt; you want to add&lt;br /&gt;
    following the same structure described before and, at the end,&lt;br /&gt;
    close the main array with&lt;br /&gt;
    )&lt;br /&gt;
&lt;br /&gt;
The element &#039;riskbitmask&#039; will be reflected in the list of icons of each row of the &#039;Override permissions&#039;-&amp;gt;roles page.&lt;br /&gt;
&lt;br /&gt;
You should add the right number of icon ranging from&lt;br /&gt;
    all four icons &lt;br /&gt;
        &#039;riskbitmask&#039; =&amp;gt; RISK_SPAM | RISK_PERSONAL | RISK_XSS | RISK_CONFIG,&lt;br /&gt;
    up to no icon at all,&lt;br /&gt;
        just removing the element &#039;riskbitmask&#039; from the array &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039;&lt;br /&gt;
&lt;br /&gt;
The element &#039;captype&#039; is ???&lt;br /&gt;
&lt;br /&gt;
The element &#039;contextlevel&#039; is ???&lt;br /&gt;
&lt;br /&gt;
The element &#039;legacy&#039; defines the legacy default for that permission. It is an array and for each each element you are allowed to choose one (and only one) of these four elements: CAP_ALLOW, CAP_PREVENT, CAP_PROHIBIT, and inherit (if you don&#039;t set it). This defines the default selected radio button in the &#039;Legacy roles&#039; page.&lt;br /&gt;
&lt;br /&gt;
== Change the version number of your &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt; ==&lt;/div&gt;</summary>
		<author><name>Daniss</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Adding_capabilities&amp;diff=34653</id>
		<title>Development:NEWMODULE Adding capabilities</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Adding_capabilities&amp;diff=34653"/>
		<updated>2008-04-07T14:29:21Z</updated>

		<summary type="html">&lt;p&gt;Daniss: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Create one access.php file in the &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;/db directory.&lt;br /&gt;
&lt;br /&gt;
It must contain&lt;br /&gt;
*the capabilities to be installed and&lt;br /&gt;
*the defaults for each standard role.&lt;br /&gt;
&lt;br /&gt;
A model of what has to be added is: &lt;br /&gt;
    $mod_glossary_capabilities = array(&lt;br /&gt;
        &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039; =&amp;gt; array(&lt;br /&gt;
            &#039;riskbitmask&#039; =&amp;gt; RISK_SPAM | RISK_PERSONAL | RISK_XSS | RISK_CONFIG,&lt;br /&gt;
            &#039;captype&#039; =&amp;gt; &#039;write&#039;,&lt;br /&gt;
            &#039;contextlevel&#039; =&amp;gt; CONTEXT_MODULE,&lt;br /&gt;
            &#039;legacy&#039; =&amp;gt; array(&lt;br /&gt;
                &#039;student&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;teacher&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;editingteacher&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;admin&#039; =&amp;gt; CAP_ALLOW&lt;br /&gt;
            )&lt;br /&gt;
        ),&lt;br /&gt;
    and you are supposed to iterate the array &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039; &lt;br /&gt;
    for each &amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt; you want to add&lt;br /&gt;
    following the same structure described before and, at the end,&lt;br /&gt;
    close the main array with&lt;br /&gt;
    )&lt;br /&gt;
&lt;br /&gt;
The element &#039;riskbitmask&#039; will be reflected in the list of icons of each row of the &#039;Override permissions&#039;-&amp;gt;roles page.&lt;br /&gt;
&lt;br /&gt;
You should add the right number of icon ranging from&lt;br /&gt;
    all four icons &lt;br /&gt;
        &#039;riskbitmask&#039; =&amp;gt; RISK_SPAM | RISK_PERSONAL | RISK_XSS | RISK_CONFIG,&lt;br /&gt;
    up to no icon at all,&lt;br /&gt;
        just removing the element &#039;riskbitmask&#039; from the array &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039;&lt;br /&gt;
&lt;br /&gt;
The element &#039;captype&#039; is ???&lt;br /&gt;
&lt;br /&gt;
The element &#039;contextlevel&#039; is ???&lt;br /&gt;
&lt;br /&gt;
The element &#039;legacy&#039; defines the legacy default for that permission. It is an array and for each each element you are allowed to choose one (and only one) of these four elements: CAP_ALLOW, CAP_PREVENT, CAP_PROHIBIT, and inherit (if you don&#039;t set it). This defines the default selected radio button in the &#039;Legacy roles&#039; page.&lt;/div&gt;</summary>
		<author><name>Daniss</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Adding_capabilities&amp;diff=34652</id>
		<title>Development:NEWMODULE Adding capabilities</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Adding_capabilities&amp;diff=34652"/>
		<updated>2008-04-07T14:28:50Z</updated>

		<summary type="html">&lt;p&gt;Daniss: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Create one access.php file in the &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;/db directory.&lt;br /&gt;
&lt;br /&gt;
It must contain&lt;br /&gt;
*the capabilities to be installed and&lt;br /&gt;
*the defaults for each standard role.&lt;br /&gt;
&lt;br /&gt;
A model of what has to be added is: &lt;br /&gt;
    $mod_glossary_capabilities = array(&lt;br /&gt;
        &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039; =&amp;gt; array(&lt;br /&gt;
            &#039;riskbitmask&#039; =&amp;gt; RISK_SPAM | RISK_PERSONAL | RISK_XSS | RISK_CONFIG,&lt;br /&gt;
            &#039;captype&#039; =&amp;gt; &#039;write&#039;,&lt;br /&gt;
            &#039;contextlevel&#039; =&amp;gt; CONTEXT_MODULE,&lt;br /&gt;
            &#039;legacy&#039; =&amp;gt; array(&lt;br /&gt;
                &#039;student&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;teacher&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;editingteacher&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;admin&#039; =&amp;gt; CAP_ALLOW&lt;br /&gt;
            )&lt;br /&gt;
        ),&lt;br /&gt;
    and you are supposed to iterate the array &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039; &lt;br /&gt;
    for each &amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt; you want to add&lt;br /&gt;
    following the same structure described before and, at the end,&lt;br /&gt;
    close the main array with&lt;br /&gt;
    )&lt;br /&gt;
&lt;br /&gt;
The element &#039;riskbitmask&#039; will be reflected in the list of icons of each row of the &#039;Override permissions&#039;-&amp;gt;roles page.&lt;br /&gt;
&lt;br /&gt;
You should add the right number of icon ranging from&lt;br /&gt;
    *all four icons &lt;br /&gt;
        &#039;riskbitmask&#039; =&amp;gt; RISK_SPAM | RISK_PERSONAL | RISK_XSS | RISK_CONFIG,&lt;br /&gt;
    *up to no icon at all,&lt;br /&gt;
        just removing the element &#039;riskbitmask&#039; from the array &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039;&lt;br /&gt;
&lt;br /&gt;
The element &#039;captype&#039; is ???&lt;br /&gt;
&lt;br /&gt;
The element &#039;contextlevel&#039; is ???&lt;br /&gt;
&lt;br /&gt;
The element &#039;legacy&#039; defines the legacy default for that permission. It is an array and for each each element you are allowed to choose one (and only one) of these four elements: CAP_ALLOW, CAP_PREVENT, CAP_PROHIBIT, and inherit (if you don&#039;t set it). This defines the default selected radio button in the &#039;Legacy roles&#039; page.&lt;/div&gt;</summary>
		<author><name>Daniss</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Adding_capabilities&amp;diff=34651</id>
		<title>Development:NEWMODULE Adding capabilities</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Adding_capabilities&amp;diff=34651"/>
		<updated>2008-04-07T14:27:34Z</updated>

		<summary type="html">&lt;p&gt;Daniss: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Create one access.php file in the &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;/db directory.&lt;br /&gt;
&lt;br /&gt;
It must contain&lt;br /&gt;
*the capabilities to be installed and&lt;br /&gt;
*the defaults for each standard role.&lt;br /&gt;
&lt;br /&gt;
A model of what has to be added is: &lt;br /&gt;
    $mod_glossary_capabilities = array(&lt;br /&gt;
        &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039; =&amp;gt; array(&lt;br /&gt;
            &#039;riskbitmask&#039; =&amp;gt; RISK_SPAM | RISK_PERSONAL | RISK_XSS | RISK_CONFIG,&lt;br /&gt;
            &#039;captype&#039; =&amp;gt; &#039;write&#039;,&lt;br /&gt;
            &#039;contextlevel&#039; =&amp;gt; CONTEXT_MODULE,&lt;br /&gt;
            &#039;legacy&#039; =&amp;gt; array(&lt;br /&gt;
                &#039;student&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;teacher&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;editingteacher&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;admin&#039; =&amp;gt; CAP_ALLOW&lt;br /&gt;
            )&lt;br /&gt;
        ),&lt;br /&gt;
    and you are supposed to iterate the array &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039; &lt;br /&gt;
    for each &amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt; you want to add&lt;br /&gt;
    following the same structure described before and, at the end,&lt;br /&gt;
    close the main array with&lt;br /&gt;
    )&lt;br /&gt;
&lt;br /&gt;
The element &#039;riskbitmask&#039; will be reflected in the list of icons of each row of the &#039;Override permissions&#039;-&amp;gt;roles page.&lt;br /&gt;
&lt;br /&gt;
You should add the right number of icon ranging from&lt;br /&gt;
    *all four icons &lt;br /&gt;
        &#039;riskbitmask&#039; =&amp;gt; RISK_SPAM | RISK_PERSONAL | RISK_XSS | RISK_CONFIG,&lt;br /&gt;
    *up to no icon at all,&lt;br /&gt;
        just removing the element &#039;riskbitmask&#039; from the array &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039;&lt;br /&gt;
&lt;br /&gt;
The element &#039;captype&#039; is ???&lt;br /&gt;
&lt;br /&gt;
The element &#039;contextlevel&#039; is ???&lt;br /&gt;
&lt;br /&gt;
The element &#039;legacy&#039; defines the legacy default for that permission. It is an array and for each each element you are allowed to choose one (and only one) of this four elements: CAP_ALLOW, CAP_PREVENT, CAP_PROHIBIT, and inherit (if you don&#039;t set it). This define the default radio button selected in the &#039;Legacy roles&#039; page.&lt;/div&gt;</summary>
		<author><name>Daniss</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Adding_capabilities&amp;diff=34650</id>
		<title>Development:NEWMODULE Adding capabilities</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Adding_capabilities&amp;diff=34650"/>
		<updated>2008-04-07T14:27:02Z</updated>

		<summary type="html">&lt;p&gt;Daniss: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Create one access.php file in the &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;/db directory.&lt;br /&gt;
&lt;br /&gt;
It must contain&lt;br /&gt;
*the capabilities to be installed and&lt;br /&gt;
*the defaults for each standard role.&lt;br /&gt;
&lt;br /&gt;
A model of what has to be added is: &lt;br /&gt;
    $mod_glossary_capabilities = array(&lt;br /&gt;
        &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039; =&amp;gt; array(&lt;br /&gt;
            &#039;riskbitmask&#039; =&amp;gt; RISK_SPAM | RISK_PERSONAL | RISK_XSS | RISK_CONFIG,&lt;br /&gt;
            &#039;captype&#039; =&amp;gt; &#039;write&#039;,&lt;br /&gt;
            &#039;contextlevel&#039; =&amp;gt; CONTEXT_MODULE,&lt;br /&gt;
            &#039;legacy&#039; =&amp;gt; array(&lt;br /&gt;
                &#039;student&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;teacher&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;editingteacher&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;admin&#039; =&amp;gt; CAP_ALLOW&lt;br /&gt;
            )&lt;br /&gt;
        ),&lt;br /&gt;
    and you are supposed to iterate the array &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039; &lt;br /&gt;
    for each &amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt; you want to add&lt;br /&gt;
    following the same structure described before and, at the end,&lt;br /&gt;
    close the main array with&lt;br /&gt;
    )&lt;br /&gt;
&lt;br /&gt;
The element &#039;riskbitmask&#039; will be reflected in the list of icons of each row of the &#039;Override permissions&#039;-&amp;gt;roles page.&lt;br /&gt;
&lt;br /&gt;
You should add the right number of icon ranging from&lt;br /&gt;
    *all four icons &lt;br /&gt;
        &#039;riskbitmask&#039; =&amp;gt; RISK_SPAM | RISK_PERSONAL | RISK_XSS | RISK_CONFIG,&lt;br /&gt;
    *up to no icon at all,&lt;br /&gt;
        just removing the element &#039;riskbitmask&#039; from the array &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039;&lt;br /&gt;
&lt;br /&gt;
The element &#039;captype&#039; is ???&lt;br /&gt;
The element &#039;contextlevel&#039; is ???&lt;br /&gt;
The element &#039;legacy&#039; define the legacy default for that permission. It is an array and for each each element you are allowed to choose one (and only one) of this four elements: CAP_ALLOW, CAP_PREVENT, CAP_PROHIBIT, and inherit (if you don&#039;t set it). This define the default radio button selected in the &#039;Legacy roles&#039; page.&lt;/div&gt;</summary>
		<author><name>Daniss</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Adding_capabilities&amp;diff=34649</id>
		<title>Development:NEWMODULE Adding capabilities</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Adding_capabilities&amp;diff=34649"/>
		<updated>2008-04-07T14:26:24Z</updated>

		<summary type="html">&lt;p&gt;Daniss: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Create one access.php file in the &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;/db directory.&lt;br /&gt;
&lt;br /&gt;
It must contain&lt;br /&gt;
*the capabilities to be installed and&lt;br /&gt;
*the defaults for each standard role.&lt;br /&gt;
&lt;br /&gt;
A model of what has to be added is: &lt;br /&gt;
    $mod_glossary_capabilities = array(&lt;br /&gt;
        &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039; =&amp;gt; array(&lt;br /&gt;
            &#039;riskbitmask&#039; =&amp;gt; RISK_SPAM | RISK_PERSONAL | RISK_XSS | RISK_CONFIG,&lt;br /&gt;
            &#039;captype&#039; =&amp;gt; &#039;write&#039;,&lt;br /&gt;
            &#039;contextlevel&#039; =&amp;gt; CONTEXT_MODULE,&lt;br /&gt;
            &#039;legacy&#039; =&amp;gt; array(&lt;br /&gt;
                &#039;student&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;teacher&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;editingteacher&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;admin&#039; =&amp;gt; CAP_ALLOW&lt;br /&gt;
            )&lt;br /&gt;
        ),&lt;br /&gt;
    and you are supposed to iterate the array &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039; &lt;br /&gt;
    for each &amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt; you want to add&lt;br /&gt;
    following the same structure described before and, at the end,&lt;br /&gt;
    close the main array with&lt;br /&gt;
    )&lt;br /&gt;
&lt;br /&gt;
The element &#039;riskbitmask&#039; will be reflected in the list of icons of each row of the &#039;Override permissions&#039;-&amp;gt;roles page. You should add the right number of icon ranging from&lt;br /&gt;
*all four icons &lt;br /&gt;
        &#039;riskbitmask&#039; =&amp;gt; RISK_SPAM | RISK_PERSONAL | RISK_XSS | RISK_CONFIG,&lt;br /&gt;
*up to no icon at all, just removing the element &#039;riskbitmask&#039; from the array &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039;&lt;br /&gt;
&lt;br /&gt;
The element &#039;captype&#039; is ???&lt;br /&gt;
The element &#039;contextlevel&#039; is ???&lt;br /&gt;
The element &#039;legacy&#039; define the legacy default for that permission. It is an array and for each each element you are allowed to choose one (and only one) of this four elements: CAP_ALLOW, CAP_PREVENT, CAP_PROHIBIT, and inherit (if you don&#039;t set it). This define the default radio button selected in the &#039;Legacy roles&#039; page.&lt;/div&gt;</summary>
		<author><name>Daniss</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Adding_capabilities&amp;diff=34648</id>
		<title>Development:NEWMODULE Adding capabilities</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Adding_capabilities&amp;diff=34648"/>
		<updated>2008-04-07T14:25:40Z</updated>

		<summary type="html">&lt;p&gt;Daniss: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Create one access.php file in the &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;/db directory.&lt;br /&gt;
It must contain&lt;br /&gt;
*the capabilities to be installed and&lt;br /&gt;
*the defaults for each standard role.&lt;br /&gt;
&lt;br /&gt;
A model of what has to be added is: &lt;br /&gt;
    $mod_glossary_capabilities = array(&lt;br /&gt;
        &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039; =&amp;gt; array(&lt;br /&gt;
            &#039;riskbitmask&#039; =&amp;gt; RISK_SPAM | RISK_PERSONAL | RISK_XSS | RISK_CONFIG,&lt;br /&gt;
            &#039;captype&#039; =&amp;gt; &#039;write&#039;,&lt;br /&gt;
            &#039;contextlevel&#039; =&amp;gt; CONTEXT_MODULE,&lt;br /&gt;
            &#039;legacy&#039; =&amp;gt; array(&lt;br /&gt;
                &#039;student&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;teacher&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;editingteacher&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;admin&#039; =&amp;gt; CAP_ALLOW&lt;br /&gt;
            )&lt;br /&gt;
        ),&lt;br /&gt;
    and you are supposed to iterate the array &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039; &lt;br /&gt;
    for each &amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt; you want to add&lt;br /&gt;
    following the same structure described before and, at the end,&lt;br /&gt;
    close the main array with&lt;br /&gt;
    )&lt;br /&gt;
&lt;br /&gt;
The element &#039;riskbitmask&#039; will be reflected in the list of icons of each row of the &#039;Override permissions&#039;-&amp;gt;roles page. You should add the right number of icon ranging from&lt;br /&gt;
*all four icons &lt;br /&gt;
        &#039;riskbitmask&#039; =&amp;gt; RISK_SPAM | RISK_PERSONAL | RISK_XSS | RISK_CONFIG,&lt;br /&gt;
*up to no icon at all, just removing the element &#039;riskbitmask&#039; from the array &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039;&lt;br /&gt;
&lt;br /&gt;
The element &#039;captype&#039; is ???&lt;br /&gt;
The element &#039;contextlevel&#039; is ???&lt;br /&gt;
The element &#039;legacy&#039; define the legacy default for that permission. It is an array and for each each element you are allowed to choose one (and only one) of this four elements: CAP_ALLOW, CAP_PREVENT, CAP_PROHIBIT, and inherit (if you don&#039;t set it). This define the default radio button selected in the &#039;Legacy roles&#039; page.&lt;/div&gt;</summary>
		<author><name>Daniss</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Adding_capabilities&amp;diff=34647</id>
		<title>Development:NEWMODULE Adding capabilities</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Adding_capabilities&amp;diff=34647"/>
		<updated>2008-04-07T14:25:19Z</updated>

		<summary type="html">&lt;p&gt;Daniss: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Create one access.php file in the &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;/db directory.&lt;br /&gt;
It must contain&lt;br /&gt;
*the capabilities to be installed and&lt;br /&gt;
*the defaults for each standard role.&lt;br /&gt;
&lt;br /&gt;
A model of what has to be added is: &lt;br /&gt;
    $mod_glossary_capabilities = array(&lt;br /&gt;
        &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039; =&amp;gt; array(&lt;br /&gt;
            &#039;riskbitmask&#039; =&amp;gt; RISK_SPAM | RISK_PERSONAL | RISK_XSS | RISK_CONFIG,&lt;br /&gt;
            &#039;captype&#039; =&amp;gt; &#039;write&#039;,&lt;br /&gt;
            &#039;contextlevel&#039; =&amp;gt; CONTEXT_MODULE,&lt;br /&gt;
            &#039;legacy&#039; =&amp;gt; array(&lt;br /&gt;
                &#039;student&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;teacher&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;editingteacher&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;admin&#039; =&amp;gt; CAP_ALLOW&lt;br /&gt;
            )&lt;br /&gt;
        ),&lt;br /&gt;
    and you are supposed to iterate the array &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;PERMISSIONNAME&amp;gt;&amp;gt;&#039; &lt;br /&gt;
    for each &amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt; you want to add&lt;br /&gt;
    following the same structure described before and, at the end,&lt;br /&gt;
    close the main array with&lt;br /&gt;
    )&lt;br /&gt;
&lt;br /&gt;
The element &#039;riskbitmask&#039; will be reflected in the list of icons of each row of the &#039;Override permissions&#039;-&amp;gt;roles page. You should add the right number of icon ranging from&lt;br /&gt;
*all four icons &lt;br /&gt;
        &#039;riskbitmask&#039; =&amp;gt; RISK_SPAM | RISK_PERSONAL | RISK_XSS | RISK_CONFIG,&lt;br /&gt;
*up to no icon at all, just removing the element &#039;riskbitmask&#039; from the array &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039;&lt;br /&gt;
&lt;br /&gt;
The element &#039;captype&#039; is ???&lt;br /&gt;
The element &#039;contextlevel&#039; is ???&lt;br /&gt;
The element &#039;legacy&#039; define the legacy default for that permission. It is an array and for each each element you are allowed to choose one (and only one) of this four elements: CAP_ALLOW, CAP_PREVENT, CAP_PROHIBIT, and inherit (if you don&#039;t set it). This define the default radio button selected in the &#039;Legacy roles&#039; page.&lt;/div&gt;</summary>
		<author><name>Daniss</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Adding_capabilities&amp;diff=34646</id>
		<title>Development:NEWMODULE Adding capabilities</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Adding_capabilities&amp;diff=34646"/>
		<updated>2008-04-07T14:24:28Z</updated>

		<summary type="html">&lt;p&gt;Daniss: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Create one access.php file in the &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;/db directory.&lt;br /&gt;
It must contain&lt;br /&gt;
*the capabilities to be installed and&lt;br /&gt;
*the defaults for each standard role.&lt;br /&gt;
&lt;br /&gt;
A model of what has to be added is: &lt;br /&gt;
    $mod_glossary_capabilities = array(&lt;br /&gt;
        &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039; =&amp;gt; array(&lt;br /&gt;
            &#039;riskbitmask&#039; =&amp;gt; RISK_SPAM | RISK_PERSONAL | RISK_XSS | RISK_CONFIG,&lt;br /&gt;
            &#039;captype&#039; =&amp;gt; &#039;write&#039;,&lt;br /&gt;
            &#039;contextlevel&#039; =&amp;gt; CONTEXT_MODULE,&lt;br /&gt;
            &#039;legacy&#039; =&amp;gt; array(&lt;br /&gt;
                &#039;student&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;teacher&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;editingteacher&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;admin&#039; =&amp;gt; CAP_ALLOW&lt;br /&gt;
            )&lt;br /&gt;
        ),&lt;br /&gt;
    iterating the array &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;PERMISSIONNAME&amp;gt;&amp;gt;&#039; &lt;br /&gt;
    for each &amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt; you want to add&lt;br /&gt;
    following the same structure described before and, at the end,&lt;br /&gt;
    closing the main array with&lt;br /&gt;
    )&lt;br /&gt;
&lt;br /&gt;
The element &#039;riskbitmask&#039; will be reflected in the list of icons of each row of the &#039;Override permissions&#039;-&amp;gt;roles page. You should add the right number of icon ranging from&lt;br /&gt;
*all four icons &lt;br /&gt;
        &#039;riskbitmask&#039; =&amp;gt; RISK_SPAM | RISK_PERSONAL | RISK_XSS | RISK_CONFIG,&lt;br /&gt;
*up to no icon at all, just removing the element &#039;riskbitmask&#039; from the array &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039;&lt;br /&gt;
&lt;br /&gt;
The element &#039;captype&#039; is ???&lt;br /&gt;
The element &#039;contextlevel&#039; is ???&lt;br /&gt;
The element &#039;legacy&#039; define the legacy default for that permission. It is an array and for each each element you are allowed to choose one (and only one) of this four elements: CAP_ALLOW, CAP_PREVENT, CAP_PROHIBIT, and inherit (if you don&#039;t set it). This define the default radio button selected in the &#039;Legacy roles&#039; page.&lt;/div&gt;</summary>
		<author><name>Daniss</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Adding_capabilities&amp;diff=34645</id>
		<title>Development:NEWMODULE Adding capabilities</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Adding_capabilities&amp;diff=34645"/>
		<updated>2008-04-07T14:23:51Z</updated>

		<summary type="html">&lt;p&gt;Daniss: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Create one access.php file in the &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;/db directory.&lt;br /&gt;
It must contain&lt;br /&gt;
*the capabilities to be installed and&lt;br /&gt;
*the defaults for each standard role.&lt;br /&gt;
&lt;br /&gt;
A model of what has to be added is: &lt;br /&gt;
    $mod_glossary_capabilities = array(&lt;br /&gt;
        &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039; =&amp;gt; array(&lt;br /&gt;
            &#039;riskbitmask&#039; =&amp;gt; RISK_SPAM | RISK_PERSONAL | RISK_XSS | RISK_CONFIG,&lt;br /&gt;
            &#039;captype&#039; =&amp;gt; &#039;write&#039;,&lt;br /&gt;
            &#039;contextlevel&#039; =&amp;gt; CONTEXT_MODULE,&lt;br /&gt;
            &#039;legacy&#039; =&amp;gt; array(&lt;br /&gt;
                &#039;student&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;teacher&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;editingteacher&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;admin&#039; =&amp;gt; CAP_ALLOW&lt;br /&gt;
            )&lt;br /&gt;
        ),&lt;br /&gt;
    iterating the array &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;PERMISSIONNAME&amp;gt;&amp;gt;&#039; &lt;br /&gt;
    for each &amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt; you want to add&lt;br /&gt;
    following the same structure and, at the end, closing the array&lt;br /&gt;
    )&lt;br /&gt;
&lt;br /&gt;
The element &#039;riskbitmask&#039; will be reflected in the list of icons of each row of the &#039;Override permissions&#039;-&amp;gt;roles page. You should add the right number of icon ranging from&lt;br /&gt;
*all four icons &lt;br /&gt;
        &#039;riskbitmask&#039; =&amp;gt; RISK_SPAM | RISK_PERSONAL | RISK_XSS | RISK_CONFIG,&lt;br /&gt;
*up to no icon at all, just removing the element &#039;riskbitmask&#039; from the array &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039;&lt;br /&gt;
&lt;br /&gt;
The element &#039;captype&#039; is ???&lt;br /&gt;
The element &#039;contextlevel&#039; is ???&lt;br /&gt;
The element &#039;legacy&#039; define the legacy default for that permission. It is an array and for each each element you are allowed to choose one (and only one) of this four elements: CAP_ALLOW, CAP_PREVENT, CAP_PROHIBIT, and inherit (if you don&#039;t set it). This define the default radio button selected in the &#039;Legacy roles&#039; page.&lt;/div&gt;</summary>
		<author><name>Daniss</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Adding_capabilities&amp;diff=34644</id>
		<title>Development:NEWMODULE Adding capabilities</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Adding_capabilities&amp;diff=34644"/>
		<updated>2008-04-07T14:23:28Z</updated>

		<summary type="html">&lt;p&gt;Daniss: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Create one access.php file in the &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;/db directory.&lt;br /&gt;
It must contain&lt;br /&gt;
*the capabilities to be installed and&lt;br /&gt;
*the defaults for each standard role.&lt;br /&gt;
&lt;br /&gt;
A model of what has to be added is: &lt;br /&gt;
    $mod_glossary_capabilities = array(&lt;br /&gt;
        &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039; =&amp;gt; array(&lt;br /&gt;
            &#039;riskbitmask&#039; =&amp;gt; RISK_SPAM | RISK_PERSONAL | RISK_XSS | RISK_CONFIG,&lt;br /&gt;
            &#039;captype&#039; =&amp;gt; &#039;write&#039;,&lt;br /&gt;
            &#039;contextlevel&#039; =&amp;gt; CONTEXT_MODULE,&lt;br /&gt;
            &#039;legacy&#039; =&amp;gt; array(&lt;br /&gt;
                &#039;student&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;teacher&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;editingteacher&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;admin&#039; =&amp;gt; CAP_ALLOW&lt;br /&gt;
            )&lt;br /&gt;
        ),&lt;br /&gt;
    iterating the array &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;PERMISSIONNAME&amp;gt;&amp;gt;&#039; for each &amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt; you want to add following the same structure and, at the end, closing the array&lt;br /&gt;
    )&lt;br /&gt;
&lt;br /&gt;
The element &#039;riskbitmask&#039; will be reflected in the list of icons of each row of the &#039;Override permissions&#039;-&amp;gt;roles page. You should add the right number of icon ranging from&lt;br /&gt;
*all four icons &lt;br /&gt;
        &#039;riskbitmask&#039; =&amp;gt; RISK_SPAM | RISK_PERSONAL | RISK_XSS | RISK_CONFIG,&lt;br /&gt;
*up to no icon at all, just removing the element &#039;riskbitmask&#039; from the array &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039;&lt;br /&gt;
&lt;br /&gt;
The element &#039;captype&#039; is ???&lt;br /&gt;
The element &#039;contextlevel&#039; is ???&lt;br /&gt;
The element &#039;legacy&#039; define the legacy default for that permission. It is an array and for each each element you are allowed to choose one (and only one) of this four elements: CAP_ALLOW, CAP_PREVENT, CAP_PROHIBIT, and inherit (if you don&#039;t set it). This define the default radio button selected in the &#039;Legacy roles&#039; page.&lt;/div&gt;</summary>
		<author><name>Daniss</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Adding_capabilities&amp;diff=34643</id>
		<title>Development:NEWMODULE Adding capabilities</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Adding_capabilities&amp;diff=34643"/>
		<updated>2008-04-07T14:23:12Z</updated>

		<summary type="html">&lt;p&gt;Daniss: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Create one access.php file in the &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;/db directory.&lt;br /&gt;
It must contain&lt;br /&gt;
*the capabilities to be installed and&lt;br /&gt;
*the defaults for each standard role.&lt;br /&gt;
&lt;br /&gt;
A model of what has to be added is: &lt;br /&gt;
    $mod_glossary_capabilities = array(&lt;br /&gt;
        &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039; =&amp;gt; array(&lt;br /&gt;
            &#039;riskbitmask&#039; =&amp;gt; RISK_SPAM | RISK_PERSONAL | RISK_XSS | RISK_CONFIG,&lt;br /&gt;
            &#039;captype&#039; =&amp;gt; &#039;write&#039;,&lt;br /&gt;
            &#039;contextlevel&#039; =&amp;gt; CONTEXT_MODULE,&lt;br /&gt;
            &#039;legacy&#039; =&amp;gt; array(&lt;br /&gt;
                &#039;student&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;teacher&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;editingteacher&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
                &#039;admin&#039; =&amp;gt; CAP_ALLOW&lt;br /&gt;
            )&lt;br /&gt;
        ),&lt;br /&gt;
    iterating the array &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;PERMISSIONNAME&amp;gt;&amp;gt;&#039; for each &amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt; you want to add following the same structure and, at the end, closing the array&lt;br /&gt;
)&lt;br /&gt;
&lt;br /&gt;
The element &#039;riskbitmask&#039; will be reflected in the list of icons of each row of the &#039;Override permissions&#039;-&amp;gt;roles page. You should add the right number of icon ranging from&lt;br /&gt;
*all four icons &lt;br /&gt;
        &#039;riskbitmask&#039; =&amp;gt; RISK_SPAM | RISK_PERSONAL | RISK_XSS | RISK_CONFIG,&lt;br /&gt;
*up to no icon at all, just removing the element &#039;riskbitmask&#039; from the array &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039;&lt;br /&gt;
&lt;br /&gt;
The element &#039;captype&#039; is ???&lt;br /&gt;
The element &#039;contextlevel&#039; is ???&lt;br /&gt;
The element &#039;legacy&#039; define the legacy default for that permission. It is an array and for each each element you are allowed to choose one (and only one) of this four elements: CAP_ALLOW, CAP_PREVENT, CAP_PROHIBIT, and inherit (if you don&#039;t set it). This define the default radio button selected in the &#039;Legacy roles&#039; page.&lt;/div&gt;</summary>
		<author><name>Daniss</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Adding_capabilities&amp;diff=34642</id>
		<title>Development:NEWMODULE Adding capabilities</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Adding_capabilities&amp;diff=34642"/>
		<updated>2008-04-07T14:21:47Z</updated>

		<summary type="html">&lt;p&gt;Daniss: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Create one access.php file in the &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;/db directory.&lt;br /&gt;
It must contain&lt;br /&gt;
*the capabilities to be installed and&lt;br /&gt;
*the defaults for each standard role.&lt;br /&gt;
&lt;br /&gt;
A model of what has to be added is: &lt;br /&gt;
    $mod_glossary_capabilities = array(&lt;br /&gt;
        &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039; =&amp;gt; array(&lt;br /&gt;
        &#039;riskbitmask&#039; =&amp;gt; RISK_SPAM | RISK_PERSONAL | RISK_XSS | RISK_CONFIG,&lt;br /&gt;
        &#039;captype&#039; =&amp;gt; &#039;write&#039;,&lt;br /&gt;
        &#039;contextlevel&#039; =&amp;gt; CONTEXT_MODULE,&lt;br /&gt;
        &#039;legacy&#039; =&amp;gt; array(&lt;br /&gt;
            &#039;student&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
            &#039;teacher&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
            &#039;editingteacher&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
            &#039;admin&#039; =&amp;gt; CAP_ALLOW&lt;br /&gt;
        )&lt;br /&gt;
    ),&lt;br /&gt;
&lt;br /&gt;
iterate the array &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;PERMISSIONNAME&amp;gt;&amp;gt;&#039; for each &amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt; you want to add following the same structure and, at the end, close the array&lt;br /&gt;
)&lt;br /&gt;
&lt;br /&gt;
The element &#039;riskbitmask&#039; will be reflected in the list of icons of each row of the &#039;Override permissions&#039;-&amp;gt;roles page. You should add the right number of icon ranging from&lt;br /&gt;
*all four icons &lt;br /&gt;
        &#039;riskbitmask&#039; =&amp;gt; RISK_SPAM | RISK_PERSONAL | RISK_XSS | RISK_CONFIG,&lt;br /&gt;
*up to no icon at all, just removing the element &#039;riskbitmask&#039; from the array &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039;&lt;br /&gt;
&lt;br /&gt;
The element &#039;captype&#039; is ???&lt;br /&gt;
The element &#039;contextlevel&#039; is ???&lt;br /&gt;
The element &#039;legacy&#039; define the legacy default for that permission. It is an array and for each each element you are allowed to choose one (and only one) of this four elements: CAP_ALLOW, CAP_PREVENT, CAP_PROHIBIT, and inherit (if you don&#039;t set it). This define the default radio button selected in the &#039;Legacy roles&#039; page.&lt;/div&gt;</summary>
		<author><name>Daniss</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Adding_capabilities&amp;diff=34641</id>
		<title>Development:NEWMODULE Adding capabilities</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Adding_capabilities&amp;diff=34641"/>
		<updated>2008-04-07T14:21:27Z</updated>

		<summary type="html">&lt;p&gt;Daniss: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Create one access.php file in the &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;/db directory.&lt;br /&gt;
It must contain&lt;br /&gt;
*the capabilities to be installed and&lt;br /&gt;
*the defaults for each standard role.&lt;br /&gt;
&lt;br /&gt;
A model of what has to be added is: &lt;br /&gt;
    $mod_glossary_capabilities = array(&lt;br /&gt;
&lt;br /&gt;
        &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039; =&amp;gt; array(&lt;br /&gt;
&lt;br /&gt;
        &#039;riskbitmask&#039; =&amp;gt; RISK_SPAM | RISK_PERSONAL | RISK_XSS | RISK_CONFIG,&lt;br /&gt;
&lt;br /&gt;
        &#039;captype&#039; =&amp;gt; &#039;write&#039;,&lt;br /&gt;
        &#039;contextlevel&#039; =&amp;gt; CONTEXT_MODULE,&lt;br /&gt;
        &#039;legacy&#039; =&amp;gt; array(&lt;br /&gt;
            &#039;student&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
            &#039;teacher&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
            &#039;editingteacher&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
            &#039;admin&#039; =&amp;gt; CAP_ALLOW&lt;br /&gt;
        )&lt;br /&gt;
    ),&lt;br /&gt;
&lt;br /&gt;
iterate the array &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;PERMISSIONNAME&amp;gt;&amp;gt;&#039; for each &amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt; you want to add following the same structure and, at the end, close the array&lt;br /&gt;
)&lt;br /&gt;
&lt;br /&gt;
The element &#039;riskbitmask&#039; will be reflected in the list of icons of each row of the &#039;Override permissions&#039;-&amp;gt;roles page. You should add the right number of icon ranging from&lt;br /&gt;
*all four icons &lt;br /&gt;
        &#039;riskbitmask&#039; =&amp;gt; RISK_SPAM | RISK_PERSONAL | RISK_XSS | RISK_CONFIG,&lt;br /&gt;
*up to no icon at all, just removing the element &#039;riskbitmask&#039; from the array &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039;&lt;br /&gt;
&lt;br /&gt;
The element &#039;captype&#039; is ???&lt;br /&gt;
The element &#039;contextlevel&#039; is ???&lt;br /&gt;
The element &#039;legacy&#039; define the legacy default for that permission. It is an array and for each each element you are allowed to choose one (and only one) of this four elements: CAP_ALLOW, CAP_PREVENT, CAP_PROHIBIT, and inherit (if you don&#039;t set it). This define the default radio button selected in the &#039;Legacy roles&#039; page.&lt;/div&gt;</summary>
		<author><name>Daniss</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Adding_capabilities&amp;diff=34640</id>
		<title>Development:NEWMODULE Adding capabilities</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Adding_capabilities&amp;diff=34640"/>
		<updated>2008-04-07T14:20:50Z</updated>

		<summary type="html">&lt;p&gt;Daniss: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Create one access.php file in the &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;/db directory.&lt;br /&gt;
It must contain&lt;br /&gt;
*the capabilities to be installed and&lt;br /&gt;
*the defaults for each standard role.&lt;br /&gt;
&lt;br /&gt;
A model of what has to be added is: &lt;br /&gt;
$mod_glossary_capabilities = array(&lt;br /&gt;
&lt;br /&gt;
&#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039; =&amp;gt; array(&lt;br /&gt;
&lt;br /&gt;
&#039;riskbitmask&#039; =&amp;gt; RISK_SPAM | RISK_PERSONAL | RISK_XSS | RISK_CONFIG,&lt;br /&gt;
&lt;br /&gt;
&#039;captype&#039; =&amp;gt; &#039;write&#039;,&lt;br /&gt;
&#039;contextlevel&#039; =&amp;gt; CONTEXT_MODULE,&lt;br /&gt;
&#039;legacy&#039; =&amp;gt; array(&lt;br /&gt;
    &#039;student&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
    &#039;teacher&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
    &#039;editingteacher&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
    &#039;admin&#039; =&amp;gt; CAP_ALLOW&lt;br /&gt;
        )&lt;br /&gt;
    ),&lt;br /&gt;
&lt;br /&gt;
iterate the array &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;PERMISSIONNAME&amp;gt;&amp;gt;&#039; for each &amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt; you want to add following the same structure and, at the end, close the array&lt;br /&gt;
)&lt;br /&gt;
&lt;br /&gt;
The element &#039;riskbitmask&#039; will be reflected in the list of icons of each row of the &#039;Override permissions&#039;-&amp;gt;roles page. You should add the right number of icon ranging from&lt;br /&gt;
*all four icons &lt;br /&gt;
        &#039;riskbitmask&#039; =&amp;gt; RISK_SPAM | RISK_PERSONAL | RISK_XSS | RISK_CONFIG,&lt;br /&gt;
*up to no icon at all, just removing the element &#039;riskbitmask&#039; from the array &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039;&lt;br /&gt;
&lt;br /&gt;
The element &#039;captype&#039; is ???&lt;br /&gt;
The element &#039;contextlevel&#039; is ???&lt;br /&gt;
The element &#039;legacy&#039; define the legacy default for that permission. It is an array and for each each element you are allowed to choose one (and only one) of this four elements: CAP_ALLOW, CAP_PREVENT, CAP_PROHIBIT, and inherit (if you don&#039;t set it). This define the default radio button selected in the &#039;Legacy roles&#039; page.&lt;/div&gt;</summary>
		<author><name>Daniss</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Adding_capabilities&amp;diff=34639</id>
		<title>Development:NEWMODULE Adding capabilities</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Adding_capabilities&amp;diff=34639"/>
		<updated>2008-04-07T14:19:48Z</updated>

		<summary type="html">&lt;p&gt;Daniss: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Create one access.php file in the &amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;/db directory.&lt;br /&gt;
It must contain&lt;br /&gt;
*the capabilities to be installed and&lt;br /&gt;
*the defaults for each standard role.&lt;br /&gt;
&lt;br /&gt;
A model of what has to be added is: &lt;br /&gt;
$mod_glossary_capabilities = array(&lt;br /&gt;
&lt;br /&gt;
    &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039; =&amp;gt; array(&lt;br /&gt;
&lt;br /&gt;
        &#039;riskbitmask&#039; =&amp;gt; RISK_SPAM | RISK_PERSONAL | RISK_XSS | RISK_CONFIG,&lt;br /&gt;
&lt;br /&gt;
        &#039;captype&#039; =&amp;gt; &#039;write&#039;,&lt;br /&gt;
        &#039;contextlevel&#039; =&amp;gt; CONTEXT_MODULE,&lt;br /&gt;
        &#039;legacy&#039; =&amp;gt; array(&lt;br /&gt;
            &#039;student&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
            &#039;teacher&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
            &#039;editingteacher&#039; =&amp;gt; CAP_ALLOW,&lt;br /&gt;
            &#039;admin&#039; =&amp;gt; CAP_ALLOW&lt;br /&gt;
        )&lt;br /&gt;
    ),&lt;br /&gt;
&lt;br /&gt;
iterate the array &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;PERMISSIONNAME&amp;gt;&amp;gt;&#039; for each &amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt; you want to add following the same structure and, at the end, close the array&lt;br /&gt;
)&lt;br /&gt;
&lt;br /&gt;
The element &#039;riskbitmask&#039; will be reflected in the list of icons of each row of the &#039;Override permissions&#039;-&amp;gt;roles page. You should add the right number of icon ranging from&lt;br /&gt;
*all four icons &lt;br /&gt;
        &#039;riskbitmask&#039; =&amp;gt; RISK_SPAM | RISK_PERSONAL | RISK_XSS | RISK_CONFIG,&lt;br /&gt;
*up to no icon at all, just removing the element &#039;riskbitmask&#039; from the array &#039;mod/&amp;lt;&amp;lt;NEWMODULE&amp;gt;&amp;gt;:&amp;lt;&amp;lt;CAPABILITYNAME&amp;gt;&amp;gt;&#039;&lt;br /&gt;
&lt;br /&gt;
The element &#039;captype&#039; is ???&lt;br /&gt;
The element &#039;contextlevel&#039; is ???&lt;br /&gt;
The element &#039;legacy&#039; define the legacy default for that permission. It is an array and for each each element you are allowed to choose one (and only one) of this four elements: CAP_ALLOW, CAP_PREVENT, CAP_PROHIBIT, and inherit (if you don&#039;t set it). This define the default radio button selected in the &#039;Legacy roles&#039; page.&lt;/div&gt;</summary>
		<author><name>Daniss</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Documentation&amp;diff=34574</id>
		<title>Development:NEWMODULE Documentation</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Documentation&amp;diff=34574"/>
		<updated>2008-04-04T17:36:34Z</updated>

		<summary type="html">&lt;p&gt;Daniss: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:Work in progress}}&lt;br /&gt;
&lt;br /&gt;
This first draft of Moodle Docs page about the creation of  anew module is divided into the following sections:&lt;br /&gt;
&lt;br /&gt;
*[[Development:NEWMODULE Tutorial]]&lt;br /&gt;
*[[Development:NEWMODULE Reference]]&lt;br /&gt;
*[[Development:NEWMODULE FAQ]]&lt;br /&gt;
*[[Development:NEWMODULE Adding capabilities]]&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
Danielle, did you know about [[Development:Modules]], which is linked to from [[Developer_documentation#Make_a_new_plugin]]? You may be better off editing that, rather than starting a new page. However don&#039;t let me discourage you. That documentation is very limited, and badly needs to be expanded, so it is absolutely brilliant that you want to work on it.--[[User:Tim Hunt|Tim Hunt]] 12:03, 28 March 2008 (CDT)&lt;br /&gt;
&lt;br /&gt;
::Good point Tim! Anyway... I think we can use this as temporary root for Daniele&#039;s work and then, simply, move things to their final place. Let&#039;s see how this evolves. -- [[User:Eloy Lafuente (stronk7)|Eloy Lafuente (stronk7)]] 12:33, 28 March 2008 (CDT)&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
[http://lyceum.open.ac.uk/temp/creating_moodle_modules.ppt My powerpoint about creating moodle modules] is a bit old (1.8) and maybe not that comprehensible but I use it when I&#039;m trying to explain things to people. It includes a list of all the things you need to have in a module, except the ones I forgot (backuplib iirc is missing). [[User:sam marshall|sam marshall]] 12:52, 28 March 2008 (CDT)&lt;br /&gt;
&lt;br /&gt;
::That&#039;s really great, Sam. For sure that presentation will help.Thanks! -- [[User:Eloy Lafuente (stronk7)|Eloy Lafuente (stronk7)]] 13:08, 28 March 2008 (CDT)&lt;/div&gt;</summary>
		<author><name>Daniss</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Reference&amp;diff=34573</id>
		<title>Development:NEWMODULE Reference</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Reference&amp;diff=34573"/>
		<updated>2008-04-04T17:02:49Z</updated>

		<summary type="html">&lt;p&gt;Daniss: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[Development:NEWMODULE Documentation|NEWMODULE Documentation]] &amp;gt; Reference&lt;br /&gt;
----&lt;br /&gt;
{{Template:Work in progress}}&lt;br /&gt;
&lt;br /&gt;
This is a first draft of the list ot the functions more frequently used into Moodle modules. Between brakets the number of occurrences of each function in the following list of 20 modules: assignment, chat, choice, data, exercise, feedback, forum, glossary, hotpot, journal, label, lams, lesson, questionnaire, quiz, resource, scorm, survey, wiki, workshop.&lt;br /&gt;
&lt;br /&gt;
== newmodule_add_instance (20) ==&lt;br /&gt;
Create a new newmodule activity&lt;br /&gt;
&lt;br /&gt;
Given an object containing all the necessary data,&lt;br /&gt;
(defined by the form in mod.html) this function&lt;br /&gt;
will create a new instance and return the id number&lt;br /&gt;
of the new instance.&lt;br /&gt;
The due data is added to the calendar.&lt;br /&gt;
This is common to all assignment types.&lt;br /&gt;
&lt;br /&gt;
== newmodule_delete_instance (20) ==&lt;br /&gt;
Deletes an assignment activity&lt;br /&gt;
&lt;br /&gt;
Deletes all database records, files and calendar events for this newmodule.&lt;br /&gt;
This is common to all assignment types.&lt;br /&gt;
== newmodule_update_instance (20) ==&lt;br /&gt;
Updates a new newmodule activity&lt;br /&gt;
&lt;br /&gt;
Given an object containing all the necessary data,&lt;br /&gt;
(defined by the form in mod.html) this function&lt;br /&gt;
will update the newmodule instance and return the id number&lt;br /&gt;
The due date is updated in the calendar&lt;br /&gt;
This is common to all assignment types.&lt;br /&gt;
&lt;br /&gt;
== newmodule_get_participants (19) ==&lt;br /&gt;
Returns the users with data in one newmodule&lt;br /&gt;
&lt;br /&gt;
(users with records in ???)&lt;br /&gt;
&lt;br /&gt;
== newmodule_user_complete (19) ==&lt;br /&gt;
Print complete information about the user&#039;s interaction with the newmodule&lt;br /&gt;
&lt;br /&gt;
== newmodule_user_outline (19) ==&lt;br /&gt;
Return an outline of the user&#039;s interaction with the assignment.&lt;br /&gt;
&lt;br /&gt;
The default method prints the grade and timemodified.&lt;br /&gt;
&lt;br /&gt;
== newmodule_get_post_actions (18) ==&lt;br /&gt;
== newmodule_get_view_actions (18) ==&lt;br /&gt;
== newmodule_cron (15) ==&lt;br /&gt;
== newmodule_reset_userdata (12) ==&lt;br /&gt;
This function is used by the reset_course_userdata function in moodlelib.&lt;br /&gt;
&lt;br /&gt;
This function will remove all posts from the specified newmodule and clean up any related data.&lt;br /&gt;
&lt;br /&gt;
== newmodule_print_recent_activity (11) ==&lt;br /&gt;
== newmodule_reset_course_form_defaults (10) ==&lt;br /&gt;
== newmodule_reset_course_form_definition (10) ==&lt;br /&gt;
Implementation of the function for printing the form elements that control&lt;br /&gt;
whether the course reset functionality affects the assignment.&lt;br /&gt;
&lt;br /&gt;
== newmodule_get_user_grades (8) ==&lt;br /&gt;
== newmodule_grade_item_delete (8) ==&lt;br /&gt;
== newmodule_grade_item_update (8) ==&lt;br /&gt;
== newmodule_grades (8) ==&lt;br /&gt;
== newmodule_update_grades (8) ==&lt;br /&gt;
== newmodule_reset_gradebook (7) ==&lt;br /&gt;
== newmodule_scale_used (7) ==&lt;br /&gt;
== newmodule_scale_used_anywhere (6) ==&lt;br /&gt;
== newmodule_get_recent_mod_activity (5) ==&lt;br /&gt;
== newmodule_log_info (5) ==&lt;br /&gt;
== newmodule_print_overview (5) ==&lt;br /&gt;
== newmodule_print_recent_mod_activity (5) ==&lt;br /&gt;
== newmodule_refresh_events (5) ==&lt;br /&gt;
== newmodule_file_area (4) ==&lt;br /&gt;
== newmodule_file_area_name (4) ==&lt;/div&gt;</summary>
		<author><name>Daniss</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Reference&amp;diff=34572</id>
		<title>Development:NEWMODULE Reference</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Reference&amp;diff=34572"/>
		<updated>2008-04-04T17:01:55Z</updated>

		<summary type="html">&lt;p&gt;Daniss: /* user_complete (19) */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[Development:NEWMODULE Documentation|NEWMODULE Documentation]] &amp;gt; Reference&lt;br /&gt;
----&lt;br /&gt;
{{Template:Work in progress}}&lt;br /&gt;
&lt;br /&gt;
This is a first draft of the list ot the functions more frequently used into Moodle modules. Between brakets the number of occurrences of each function in the following list of 20 modules: assignment, chat, choice, data, exercise, feedback, forum, glossary, hotpot, journal, label, lams, lesson, questionnaire, quiz, resource, scorm, survey, wiki, workshop.&lt;br /&gt;
&lt;br /&gt;
== add_instance (20) ==&lt;br /&gt;
Create a new newmodule activity&lt;br /&gt;
&lt;br /&gt;
Given an object containing all the necessary data,&lt;br /&gt;
(defined by the form in mod.html) this function&lt;br /&gt;
will create a new instance and return the id number&lt;br /&gt;
of the new instance.&lt;br /&gt;
The due data is added to the calendar.&lt;br /&gt;
This is common to all assignment types.&lt;br /&gt;
&lt;br /&gt;
== delete_instance (20) ==&lt;br /&gt;
Deletes an assignment activity&lt;br /&gt;
&lt;br /&gt;
Deletes all database records, files and calendar events for this newmodule.&lt;br /&gt;
This is common to all assignment types.&lt;br /&gt;
== newmodule_update_instance (20) ==&lt;br /&gt;
Updates a new newmodule activity&lt;br /&gt;
&lt;br /&gt;
Given an object containing all the necessary data,&lt;br /&gt;
(defined by the form in mod.html) this function&lt;br /&gt;
will update the newmodule instance and return the id number&lt;br /&gt;
The due date is updated in the calendar&lt;br /&gt;
This is common to all assignment types.&lt;br /&gt;
&lt;br /&gt;
== newmodule_get_participants (19) ==&lt;br /&gt;
Returns the users with data in one newmodule&lt;br /&gt;
&lt;br /&gt;
(users with records in ???)&lt;br /&gt;
&lt;br /&gt;
== newmodule_user_complete (19) ==&lt;br /&gt;
Print complete information about the user&#039;s interaction with the newmodule&lt;br /&gt;
&lt;br /&gt;
== user_outline (19) ==&lt;br /&gt;
Return an outline of the user&#039;s interaction with the assignment.&lt;br /&gt;
&lt;br /&gt;
The default method prints the grade and timemodified.&lt;br /&gt;
&lt;br /&gt;
== get_post_actions (18) ==&lt;br /&gt;
== get_view_actions (18) ==&lt;br /&gt;
== cron (15) ==&lt;br /&gt;
== reset_userdata (12) ==&lt;br /&gt;
This function is used by the reset_course_userdata function in moodlelib.&lt;br /&gt;
&lt;br /&gt;
This function will remove all posts from the specified newmodule and clean up any related data.&lt;br /&gt;
&lt;br /&gt;
== print_recent_activity (11) ==&lt;br /&gt;
== reset_course_form_defaults (10) ==&lt;br /&gt;
== reset_course_form_definition (10) ==&lt;br /&gt;
Implementation of the function for printing the form elements that control&lt;br /&gt;
whether the course reset functionality affects the assignment.&lt;br /&gt;
&lt;br /&gt;
== get_user_grades (8) ==&lt;br /&gt;
== grade_item_delete (8) ==&lt;br /&gt;
== grade_item_update (8) ==&lt;br /&gt;
== grades (8) ==&lt;br /&gt;
== update_grades (8) ==&lt;br /&gt;
== reset_gradebook (7) ==&lt;br /&gt;
== scale_used (7) ==&lt;br /&gt;
== scale_used_anywhere (6) ==&lt;br /&gt;
== get_recent_mod_activity (5) ==&lt;br /&gt;
== log_info (5) ==&lt;br /&gt;
== print_overview (5) ==&lt;br /&gt;
== print_recent_mod_activity (5) ==&lt;br /&gt;
== refresh_events (5) ==&lt;br /&gt;
== file_area (4) ==&lt;br /&gt;
== file_area_name (4) ==&lt;/div&gt;</summary>
		<author><name>Daniss</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Reference&amp;diff=34571</id>
		<title>Development:NEWMODULE Reference</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Reference&amp;diff=34571"/>
		<updated>2008-04-04T17:01:22Z</updated>

		<summary type="html">&lt;p&gt;Daniss: /* &amp;lt;&amp;lt;newmodule&amp;gt;&amp;gt;_update_instance (20) */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[Development:NEWMODULE Documentation|NEWMODULE Documentation]] &amp;gt; Reference&lt;br /&gt;
----&lt;br /&gt;
{{Template:Work in progress}}&lt;br /&gt;
&lt;br /&gt;
This is a first draft of the list ot the functions more frequently used into Moodle modules. Between brakets the number of occurrences of each function in the following list of 20 modules: assignment, chat, choice, data, exercise, feedback, forum, glossary, hotpot, journal, label, lams, lesson, questionnaire, quiz, resource, scorm, survey, wiki, workshop.&lt;br /&gt;
&lt;br /&gt;
== add_instance (20) ==&lt;br /&gt;
Create a new newmodule activity&lt;br /&gt;
&lt;br /&gt;
Given an object containing all the necessary data,&lt;br /&gt;
(defined by the form in mod.html) this function&lt;br /&gt;
will create a new instance and return the id number&lt;br /&gt;
of the new instance.&lt;br /&gt;
The due data is added to the calendar.&lt;br /&gt;
This is common to all assignment types.&lt;br /&gt;
&lt;br /&gt;
== delete_instance (20) ==&lt;br /&gt;
Deletes an assignment activity&lt;br /&gt;
&lt;br /&gt;
Deletes all database records, files and calendar events for this newmodule.&lt;br /&gt;
This is common to all assignment types.&lt;br /&gt;
== newmodule_update_instance (20) ==&lt;br /&gt;
Updates a new newmodule activity&lt;br /&gt;
&lt;br /&gt;
Given an object containing all the necessary data,&lt;br /&gt;
(defined by the form in mod.html) this function&lt;br /&gt;
will update the newmodule instance and return the id number&lt;br /&gt;
The due date is updated in the calendar&lt;br /&gt;
This is common to all assignment types.&lt;br /&gt;
&lt;br /&gt;
== newmodule_get_participants (19) ==&lt;br /&gt;
Returns the users with data in one newmodule&lt;br /&gt;
&lt;br /&gt;
(users with records in ???)&lt;br /&gt;
&lt;br /&gt;
== user_complete (19) ==&lt;br /&gt;
Print complete information about the user&#039;s interaction with the newmodule&lt;br /&gt;
&lt;br /&gt;
== user_outline (19) ==&lt;br /&gt;
Return an outline of the user&#039;s interaction with the assignment.&lt;br /&gt;
&lt;br /&gt;
The default method prints the grade and timemodified.&lt;br /&gt;
&lt;br /&gt;
== get_post_actions (18) ==&lt;br /&gt;
== get_view_actions (18) ==&lt;br /&gt;
== cron (15) ==&lt;br /&gt;
== reset_userdata (12) ==&lt;br /&gt;
This function is used by the reset_course_userdata function in moodlelib.&lt;br /&gt;
&lt;br /&gt;
This function will remove all posts from the specified newmodule and clean up any related data.&lt;br /&gt;
&lt;br /&gt;
== print_recent_activity (11) ==&lt;br /&gt;
== reset_course_form_defaults (10) ==&lt;br /&gt;
== reset_course_form_definition (10) ==&lt;br /&gt;
Implementation of the function for printing the form elements that control&lt;br /&gt;
whether the course reset functionality affects the assignment.&lt;br /&gt;
&lt;br /&gt;
== get_user_grades (8) ==&lt;br /&gt;
== grade_item_delete (8) ==&lt;br /&gt;
== grade_item_update (8) ==&lt;br /&gt;
== grades (8) ==&lt;br /&gt;
== update_grades (8) ==&lt;br /&gt;
== reset_gradebook (7) ==&lt;br /&gt;
== scale_used (7) ==&lt;br /&gt;
== scale_used_anywhere (6) ==&lt;br /&gt;
== get_recent_mod_activity (5) ==&lt;br /&gt;
== log_info (5) ==&lt;br /&gt;
== print_overview (5) ==&lt;br /&gt;
== print_recent_mod_activity (5) ==&lt;br /&gt;
== refresh_events (5) ==&lt;br /&gt;
== file_area (4) ==&lt;br /&gt;
== file_area_name (4) ==&lt;/div&gt;</summary>
		<author><name>Daniss</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Reference&amp;diff=34570</id>
		<title>Development:NEWMODULE Reference</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Reference&amp;diff=34570"/>
		<updated>2008-04-04T17:01:05Z</updated>

		<summary type="html">&lt;p&gt;Daniss: /* update_instance (20) */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[Development:NEWMODULE Documentation|NEWMODULE Documentation]] &amp;gt; Reference&lt;br /&gt;
----&lt;br /&gt;
{{Template:Work in progress}}&lt;br /&gt;
&lt;br /&gt;
This is a first draft of the list ot the functions more frequently used into Moodle modules. Between brakets the number of occurrences of each function in the following list of 20 modules: assignment, chat, choice, data, exercise, feedback, forum, glossary, hotpot, journal, label, lams, lesson, questionnaire, quiz, resource, scorm, survey, wiki, workshop.&lt;br /&gt;
&lt;br /&gt;
== add_instance (20) ==&lt;br /&gt;
Create a new newmodule activity&lt;br /&gt;
&lt;br /&gt;
Given an object containing all the necessary data,&lt;br /&gt;
(defined by the form in mod.html) this function&lt;br /&gt;
will create a new instance and return the id number&lt;br /&gt;
of the new instance.&lt;br /&gt;
The due data is added to the calendar.&lt;br /&gt;
This is common to all assignment types.&lt;br /&gt;
&lt;br /&gt;
== delete_instance (20) ==&lt;br /&gt;
Deletes an assignment activity&lt;br /&gt;
&lt;br /&gt;
Deletes all database records, files and calendar events for this newmodule.&lt;br /&gt;
This is common to all assignment types.&lt;br /&gt;
== &amp;lt;&amp;lt;newmodule&amp;gt;&amp;gt;_update_instance (20) ==&lt;br /&gt;
Updates a new newmodule activity&lt;br /&gt;
&lt;br /&gt;
Given an object containing all the necessary data,&lt;br /&gt;
(defined by the form in mod.html) this function&lt;br /&gt;
will update the newmodule instance and return the id number&lt;br /&gt;
The due date is updated in the calendar&lt;br /&gt;
This is common to all assignment types.&lt;br /&gt;
&lt;br /&gt;
== newmodule_get_participants (19) ==&lt;br /&gt;
Returns the users with data in one newmodule&lt;br /&gt;
&lt;br /&gt;
(users with records in ???)&lt;br /&gt;
&lt;br /&gt;
== user_complete (19) ==&lt;br /&gt;
Print complete information about the user&#039;s interaction with the newmodule&lt;br /&gt;
&lt;br /&gt;
== user_outline (19) ==&lt;br /&gt;
Return an outline of the user&#039;s interaction with the assignment.&lt;br /&gt;
&lt;br /&gt;
The default method prints the grade and timemodified.&lt;br /&gt;
&lt;br /&gt;
== get_post_actions (18) ==&lt;br /&gt;
== get_view_actions (18) ==&lt;br /&gt;
== cron (15) ==&lt;br /&gt;
== reset_userdata (12) ==&lt;br /&gt;
This function is used by the reset_course_userdata function in moodlelib.&lt;br /&gt;
&lt;br /&gt;
This function will remove all posts from the specified newmodule and clean up any related data.&lt;br /&gt;
&lt;br /&gt;
== print_recent_activity (11) ==&lt;br /&gt;
== reset_course_form_defaults (10) ==&lt;br /&gt;
== reset_course_form_definition (10) ==&lt;br /&gt;
Implementation of the function for printing the form elements that control&lt;br /&gt;
whether the course reset functionality affects the assignment.&lt;br /&gt;
&lt;br /&gt;
== get_user_grades (8) ==&lt;br /&gt;
== grade_item_delete (8) ==&lt;br /&gt;
== grade_item_update (8) ==&lt;br /&gt;
== grades (8) ==&lt;br /&gt;
== update_grades (8) ==&lt;br /&gt;
== reset_gradebook (7) ==&lt;br /&gt;
== scale_used (7) ==&lt;br /&gt;
== scale_used_anywhere (6) ==&lt;br /&gt;
== get_recent_mod_activity (5) ==&lt;br /&gt;
== log_info (5) ==&lt;br /&gt;
== print_overview (5) ==&lt;br /&gt;
== print_recent_mod_activity (5) ==&lt;br /&gt;
== refresh_events (5) ==&lt;br /&gt;
== file_area (4) ==&lt;br /&gt;
== file_area_name (4) ==&lt;/div&gt;</summary>
		<author><name>Daniss</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Reference&amp;diff=34510</id>
		<title>Development:NEWMODULE Reference</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Reference&amp;diff=34510"/>
		<updated>2008-04-03T18:33:25Z</updated>

		<summary type="html">&lt;p&gt;Daniss: /* reset_course_form_definition (10) */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[Development:NEWMODULE Documentation|NEWMODULE Documentation]] &amp;gt; Reference&lt;br /&gt;
----&lt;br /&gt;
{{Template:Work in progress}}&lt;br /&gt;
&lt;br /&gt;
This is a first draft of the list ot the functions more frequently used into Moodle modules. Between brakets the number of occurrences of each function in the following list of 20 modules: assignment, chat, choice, data, exercise, feedback, forum, glossary, hotpot, journal, label, lams, lesson, questionnaire, quiz, resource, scorm, survey, wiki, workshop.&lt;br /&gt;
&lt;br /&gt;
== add_instance (20) ==&lt;br /&gt;
Create a new newmodule activity&lt;br /&gt;
&lt;br /&gt;
Given an object containing all the necessary data,&lt;br /&gt;
(defined by the form in mod.html) this function&lt;br /&gt;
will create a new instance and return the id number&lt;br /&gt;
of the new instance.&lt;br /&gt;
The due data is added to the calendar.&lt;br /&gt;
This is common to all assignment types.&lt;br /&gt;
&lt;br /&gt;
== delete_instance (20) ==&lt;br /&gt;
Deletes an assignment activity&lt;br /&gt;
&lt;br /&gt;
Deletes all database records, files and calendar events for this newmodule.&lt;br /&gt;
This is common to all assignment types.&lt;br /&gt;
== update_instance (20) ==&lt;br /&gt;
Updates a new newmodule activity&lt;br /&gt;
&lt;br /&gt;
Given an object containing all the necessary data,&lt;br /&gt;
(defined by the form in mod.html) this function&lt;br /&gt;
will update the newmodule instance and return the id number&lt;br /&gt;
The due date is updated in the calendar&lt;br /&gt;
This is common to all assignment types.&lt;br /&gt;
== newmodule_get_participants (19) ==&lt;br /&gt;
Returns the users with data in one newmodule&lt;br /&gt;
&lt;br /&gt;
(users with records in ???)&lt;br /&gt;
&lt;br /&gt;
== user_complete (19) ==&lt;br /&gt;
Print complete information about the user&#039;s interaction with the newmodule&lt;br /&gt;
&lt;br /&gt;
== user_outline (19) ==&lt;br /&gt;
Return an outline of the user&#039;s interaction with the assignment.&lt;br /&gt;
&lt;br /&gt;
The default method prints the grade and timemodified.&lt;br /&gt;
&lt;br /&gt;
== get_post_actions (18) ==&lt;br /&gt;
== get_view_actions (18) ==&lt;br /&gt;
== cron (15) ==&lt;br /&gt;
== reset_userdata (12) ==&lt;br /&gt;
This function is used by the reset_course_userdata function in moodlelib.&lt;br /&gt;
&lt;br /&gt;
This function will remove all posts from the specified newmodule and clean up any related data.&lt;br /&gt;
&lt;br /&gt;
== print_recent_activity (11) ==&lt;br /&gt;
== reset_course_form_defaults (10) ==&lt;br /&gt;
== reset_course_form_definition (10) ==&lt;br /&gt;
Implementation of the function for printing the form elements that control&lt;br /&gt;
whether the course reset functionality affects the assignment.&lt;br /&gt;
&lt;br /&gt;
== get_user_grades (8) ==&lt;br /&gt;
== grade_item_delete (8) ==&lt;br /&gt;
== grade_item_update (8) ==&lt;br /&gt;
== grades (8) ==&lt;br /&gt;
== update_grades (8) ==&lt;br /&gt;
== reset_gradebook (7) ==&lt;br /&gt;
== scale_used (7) ==&lt;br /&gt;
== scale_used_anywhere (6) ==&lt;br /&gt;
== get_recent_mod_activity (5) ==&lt;br /&gt;
== log_info (5) ==&lt;br /&gt;
== print_overview (5) ==&lt;br /&gt;
== print_recent_mod_activity (5) ==&lt;br /&gt;
== refresh_events (5) ==&lt;br /&gt;
== file_area (4) ==&lt;br /&gt;
== file_area_name (4) ==&lt;/div&gt;</summary>
		<author><name>Daniss</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Reference&amp;diff=34509</id>
		<title>Development:NEWMODULE Reference</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Reference&amp;diff=34509"/>
		<updated>2008-04-03T18:31:52Z</updated>

		<summary type="html">&lt;p&gt;Daniss: /* reset_userdata (12) */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[Development:NEWMODULE Documentation|NEWMODULE Documentation]] &amp;gt; Reference&lt;br /&gt;
----&lt;br /&gt;
{{Template:Work in progress}}&lt;br /&gt;
&lt;br /&gt;
This is a first draft of the list ot the functions more frequently used into Moodle modules. Between brakets the number of occurrences of each function in the following list of 20 modules: assignment, chat, choice, data, exercise, feedback, forum, glossary, hotpot, journal, label, lams, lesson, questionnaire, quiz, resource, scorm, survey, wiki, workshop.&lt;br /&gt;
&lt;br /&gt;
== add_instance (20) ==&lt;br /&gt;
Create a new newmodule activity&lt;br /&gt;
&lt;br /&gt;
Given an object containing all the necessary data,&lt;br /&gt;
(defined by the form in mod.html) this function&lt;br /&gt;
will create a new instance and return the id number&lt;br /&gt;
of the new instance.&lt;br /&gt;
The due data is added to the calendar.&lt;br /&gt;
This is common to all assignment types.&lt;br /&gt;
&lt;br /&gt;
== delete_instance (20) ==&lt;br /&gt;
Deletes an assignment activity&lt;br /&gt;
&lt;br /&gt;
Deletes all database records, files and calendar events for this newmodule.&lt;br /&gt;
This is common to all assignment types.&lt;br /&gt;
== update_instance (20) ==&lt;br /&gt;
Updates a new newmodule activity&lt;br /&gt;
&lt;br /&gt;
Given an object containing all the necessary data,&lt;br /&gt;
(defined by the form in mod.html) this function&lt;br /&gt;
will update the newmodule instance and return the id number&lt;br /&gt;
The due date is updated in the calendar&lt;br /&gt;
This is common to all assignment types.&lt;br /&gt;
== newmodule_get_participants (19) ==&lt;br /&gt;
Returns the users with data in one newmodule&lt;br /&gt;
&lt;br /&gt;
(users with records in ???)&lt;br /&gt;
&lt;br /&gt;
== user_complete (19) ==&lt;br /&gt;
Print complete information about the user&#039;s interaction with the newmodule&lt;br /&gt;
&lt;br /&gt;
== user_outline (19) ==&lt;br /&gt;
Return an outline of the user&#039;s interaction with the assignment.&lt;br /&gt;
&lt;br /&gt;
The default method prints the grade and timemodified.&lt;br /&gt;
&lt;br /&gt;
== get_post_actions (18) ==&lt;br /&gt;
== get_view_actions (18) ==&lt;br /&gt;
== cron (15) ==&lt;br /&gt;
== reset_userdata (12) ==&lt;br /&gt;
This function is used by the reset_course_userdata function in moodlelib.&lt;br /&gt;
&lt;br /&gt;
This function will remove all posts from the specified newmodule and clean up any related data.&lt;br /&gt;
&lt;br /&gt;
== print_recent_activity (11) ==&lt;br /&gt;
== reset_course_form_defaults (10) ==&lt;br /&gt;
== reset_course_form_definition (10) ==&lt;br /&gt;
== get_user_grades (8) ==&lt;br /&gt;
== grade_item_delete (8) ==&lt;br /&gt;
== grade_item_update (8) ==&lt;br /&gt;
== grades (8) ==&lt;br /&gt;
== update_grades (8) ==&lt;br /&gt;
== reset_gradebook (7) ==&lt;br /&gt;
== scale_used (7) ==&lt;br /&gt;
== scale_used_anywhere (6) ==&lt;br /&gt;
== get_recent_mod_activity (5) ==&lt;br /&gt;
== log_info (5) ==&lt;br /&gt;
== print_overview (5) ==&lt;br /&gt;
== print_recent_mod_activity (5) ==&lt;br /&gt;
== refresh_events (5) ==&lt;br /&gt;
== file_area (4) ==&lt;br /&gt;
== file_area_name (4) ==&lt;/div&gt;</summary>
		<author><name>Daniss</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Reference&amp;diff=34508</id>
		<title>Development:NEWMODULE Reference</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Reference&amp;diff=34508"/>
		<updated>2008-04-03T18:27:12Z</updated>

		<summary type="html">&lt;p&gt;Daniss: /* newmodule_get_participants (19) */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[Development:NEWMODULE Documentation|NEWMODULE Documentation]] &amp;gt; Reference&lt;br /&gt;
----&lt;br /&gt;
{{Template:Work in progress}}&lt;br /&gt;
&lt;br /&gt;
This is a first draft of the list ot the functions more frequently used into Moodle modules. Between brakets the number of occurrences of each function in the following list of 20 modules: assignment, chat, choice, data, exercise, feedback, forum, glossary, hotpot, journal, label, lams, lesson, questionnaire, quiz, resource, scorm, survey, wiki, workshop.&lt;br /&gt;
&lt;br /&gt;
== add_instance (20) ==&lt;br /&gt;
Create a new newmodule activity&lt;br /&gt;
&lt;br /&gt;
Given an object containing all the necessary data,&lt;br /&gt;
(defined by the form in mod.html) this function&lt;br /&gt;
will create a new instance and return the id number&lt;br /&gt;
of the new instance.&lt;br /&gt;
The due data is added to the calendar.&lt;br /&gt;
This is common to all assignment types.&lt;br /&gt;
&lt;br /&gt;
== delete_instance (20) ==&lt;br /&gt;
Deletes an assignment activity&lt;br /&gt;
&lt;br /&gt;
Deletes all database records, files and calendar events for this newmodule.&lt;br /&gt;
This is common to all assignment types.&lt;br /&gt;
== update_instance (20) ==&lt;br /&gt;
Updates a new newmodule activity&lt;br /&gt;
&lt;br /&gt;
Given an object containing all the necessary data,&lt;br /&gt;
(defined by the form in mod.html) this function&lt;br /&gt;
will update the newmodule instance and return the id number&lt;br /&gt;
The due date is updated in the calendar&lt;br /&gt;
This is common to all assignment types.&lt;br /&gt;
== newmodule_get_participants (19) ==&lt;br /&gt;
Returns the users with data in one newmodule&lt;br /&gt;
&lt;br /&gt;
(users with records in ???)&lt;br /&gt;
&lt;br /&gt;
== user_complete (19) ==&lt;br /&gt;
Print complete information about the user&#039;s interaction with the newmodule&lt;br /&gt;
&lt;br /&gt;
== user_outline (19) ==&lt;br /&gt;
Return an outline of the user&#039;s interaction with the assignment.&lt;br /&gt;
&lt;br /&gt;
The default method prints the grade and timemodified.&lt;br /&gt;
&lt;br /&gt;
== get_post_actions (18) ==&lt;br /&gt;
== get_view_actions (18) ==&lt;br /&gt;
== cron (15) ==&lt;br /&gt;
== reset_userdata (12) ==&lt;br /&gt;
== print_recent_activity (11) ==&lt;br /&gt;
== reset_course_form_defaults (10) ==&lt;br /&gt;
== reset_course_form_definition (10) ==&lt;br /&gt;
== get_user_grades (8) ==&lt;br /&gt;
== grade_item_delete (8) ==&lt;br /&gt;
== grade_item_update (8) ==&lt;br /&gt;
== grades (8) ==&lt;br /&gt;
== update_grades (8) ==&lt;br /&gt;
== reset_gradebook (7) ==&lt;br /&gt;
== scale_used (7) ==&lt;br /&gt;
== scale_used_anywhere (6) ==&lt;br /&gt;
== get_recent_mod_activity (5) ==&lt;br /&gt;
== log_info (5) ==&lt;br /&gt;
== print_overview (5) ==&lt;br /&gt;
== print_recent_mod_activity (5) ==&lt;br /&gt;
== refresh_events (5) ==&lt;br /&gt;
== file_area (4) ==&lt;br /&gt;
== file_area_name (4) ==&lt;/div&gt;</summary>
		<author><name>Daniss</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Reference&amp;diff=34507</id>
		<title>Development:NEWMODULE Reference</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Reference&amp;diff=34507"/>
		<updated>2008-04-03T18:26:56Z</updated>

		<summary type="html">&lt;p&gt;Daniss: /* get_participants (19) */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[Development:NEWMODULE Documentation|NEWMODULE Documentation]] &amp;gt; Reference&lt;br /&gt;
----&lt;br /&gt;
{{Template:Work in progress}}&lt;br /&gt;
&lt;br /&gt;
This is a first draft of the list ot the functions more frequently used into Moodle modules. Between brakets the number of occurrences of each function in the following list of 20 modules: assignment, chat, choice, data, exercise, feedback, forum, glossary, hotpot, journal, label, lams, lesson, questionnaire, quiz, resource, scorm, survey, wiki, workshop.&lt;br /&gt;
&lt;br /&gt;
== add_instance (20) ==&lt;br /&gt;
Create a new newmodule activity&lt;br /&gt;
&lt;br /&gt;
Given an object containing all the necessary data,&lt;br /&gt;
(defined by the form in mod.html) this function&lt;br /&gt;
will create a new instance and return the id number&lt;br /&gt;
of the new instance.&lt;br /&gt;
The due data is added to the calendar.&lt;br /&gt;
This is common to all assignment types.&lt;br /&gt;
&lt;br /&gt;
== delete_instance (20) ==&lt;br /&gt;
Deletes an assignment activity&lt;br /&gt;
&lt;br /&gt;
Deletes all database records, files and calendar events for this newmodule.&lt;br /&gt;
This is common to all assignment types.&lt;br /&gt;
== update_instance (20) ==&lt;br /&gt;
Updates a new newmodule activity&lt;br /&gt;
&lt;br /&gt;
Given an object containing all the necessary data,&lt;br /&gt;
(defined by the form in mod.html) this function&lt;br /&gt;
will update the newmodule instance and return the id number&lt;br /&gt;
The due date is updated in the calendar&lt;br /&gt;
This is common to all assignment types.&lt;br /&gt;
== newmodule_get_participants (19) ==&lt;br /&gt;
Returns the users with data in one newmodule&lt;br /&gt;
(users with records in ???)&lt;br /&gt;
&lt;br /&gt;
== user_complete (19) ==&lt;br /&gt;
Print complete information about the user&#039;s interaction with the newmodule&lt;br /&gt;
&lt;br /&gt;
== user_outline (19) ==&lt;br /&gt;
Return an outline of the user&#039;s interaction with the assignment.&lt;br /&gt;
&lt;br /&gt;
The default method prints the grade and timemodified.&lt;br /&gt;
&lt;br /&gt;
== get_post_actions (18) ==&lt;br /&gt;
== get_view_actions (18) ==&lt;br /&gt;
== cron (15) ==&lt;br /&gt;
== reset_userdata (12) ==&lt;br /&gt;
== print_recent_activity (11) ==&lt;br /&gt;
== reset_course_form_defaults (10) ==&lt;br /&gt;
== reset_course_form_definition (10) ==&lt;br /&gt;
== get_user_grades (8) ==&lt;br /&gt;
== grade_item_delete (8) ==&lt;br /&gt;
== grade_item_update (8) ==&lt;br /&gt;
== grades (8) ==&lt;br /&gt;
== update_grades (8) ==&lt;br /&gt;
== reset_gradebook (7) ==&lt;br /&gt;
== scale_used (7) ==&lt;br /&gt;
== scale_used_anywhere (6) ==&lt;br /&gt;
== get_recent_mod_activity (5) ==&lt;br /&gt;
== log_info (5) ==&lt;br /&gt;
== print_overview (5) ==&lt;br /&gt;
== print_recent_mod_activity (5) ==&lt;br /&gt;
== refresh_events (5) ==&lt;br /&gt;
== file_area (4) ==&lt;br /&gt;
== file_area_name (4) ==&lt;/div&gt;</summary>
		<author><name>Daniss</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Reference&amp;diff=34506</id>
		<title>Development:NEWMODULE Reference</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Reference&amp;diff=34506"/>
		<updated>2008-04-03T18:22:54Z</updated>

		<summary type="html">&lt;p&gt;Daniss: /* user_outline (19) */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[Development:NEWMODULE Documentation|NEWMODULE Documentation]] &amp;gt; Reference&lt;br /&gt;
----&lt;br /&gt;
{{Template:Work in progress}}&lt;br /&gt;
&lt;br /&gt;
This is a first draft of the list ot the functions more frequently used into Moodle modules. Between brakets the number of occurrences of each function in the following list of 20 modules: assignment, chat, choice, data, exercise, feedback, forum, glossary, hotpot, journal, label, lams, lesson, questionnaire, quiz, resource, scorm, survey, wiki, workshop.&lt;br /&gt;
&lt;br /&gt;
== add_instance (20) ==&lt;br /&gt;
Create a new newmodule activity&lt;br /&gt;
&lt;br /&gt;
Given an object containing all the necessary data,&lt;br /&gt;
(defined by the form in mod.html) this function&lt;br /&gt;
will create a new instance and return the id number&lt;br /&gt;
of the new instance.&lt;br /&gt;
The due data is added to the calendar.&lt;br /&gt;
This is common to all assignment types.&lt;br /&gt;
&lt;br /&gt;
== delete_instance (20) ==&lt;br /&gt;
Deletes an assignment activity&lt;br /&gt;
&lt;br /&gt;
Deletes all database records, files and calendar events for this newmodule.&lt;br /&gt;
This is common to all assignment types.&lt;br /&gt;
== update_instance (20) ==&lt;br /&gt;
Updates a new newmodule activity&lt;br /&gt;
&lt;br /&gt;
Given an object containing all the necessary data,&lt;br /&gt;
(defined by the form in mod.html) this function&lt;br /&gt;
will update the newmodule instance and return the id number&lt;br /&gt;
The due date is updated in the calendar&lt;br /&gt;
This is common to all assignment types.&lt;br /&gt;
== get_participants (19) ==&lt;br /&gt;
== user_complete (19) ==&lt;br /&gt;
Print complete information about the user&#039;s interaction with the newmodule&lt;br /&gt;
&lt;br /&gt;
== user_outline (19) ==&lt;br /&gt;
Return an outline of the user&#039;s interaction with the assignment.&lt;br /&gt;
&lt;br /&gt;
The default method prints the grade and timemodified.&lt;br /&gt;
&lt;br /&gt;
== get_post_actions (18) ==&lt;br /&gt;
== get_view_actions (18) ==&lt;br /&gt;
== cron (15) ==&lt;br /&gt;
== reset_userdata (12) ==&lt;br /&gt;
== print_recent_activity (11) ==&lt;br /&gt;
== reset_course_form_defaults (10) ==&lt;br /&gt;
== reset_course_form_definition (10) ==&lt;br /&gt;
== get_user_grades (8) ==&lt;br /&gt;
== grade_item_delete (8) ==&lt;br /&gt;
== grade_item_update (8) ==&lt;br /&gt;
== grades (8) ==&lt;br /&gt;
== update_grades (8) ==&lt;br /&gt;
== reset_gradebook (7) ==&lt;br /&gt;
== scale_used (7) ==&lt;br /&gt;
== scale_used_anywhere (6) ==&lt;br /&gt;
== get_recent_mod_activity (5) ==&lt;br /&gt;
== log_info (5) ==&lt;br /&gt;
== print_overview (5) ==&lt;br /&gt;
== print_recent_mod_activity (5) ==&lt;br /&gt;
== refresh_events (5) ==&lt;br /&gt;
== file_area (4) ==&lt;br /&gt;
== file_area_name (4) ==&lt;/div&gt;</summary>
		<author><name>Daniss</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Reference&amp;diff=34505</id>
		<title>Development:NEWMODULE Reference</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Reference&amp;diff=34505"/>
		<updated>2008-04-03T18:22:07Z</updated>

		<summary type="html">&lt;p&gt;Daniss: /* user_complete (19) */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[Development:NEWMODULE Documentation|NEWMODULE Documentation]] &amp;gt; Reference&lt;br /&gt;
----&lt;br /&gt;
{{Template:Work in progress}}&lt;br /&gt;
&lt;br /&gt;
This is a first draft of the list ot the functions more frequently used into Moodle modules. Between brakets the number of occurrences of each function in the following list of 20 modules: assignment, chat, choice, data, exercise, feedback, forum, glossary, hotpot, journal, label, lams, lesson, questionnaire, quiz, resource, scorm, survey, wiki, workshop.&lt;br /&gt;
&lt;br /&gt;
== add_instance (20) ==&lt;br /&gt;
Create a new newmodule activity&lt;br /&gt;
&lt;br /&gt;
Given an object containing all the necessary data,&lt;br /&gt;
(defined by the form in mod.html) this function&lt;br /&gt;
will create a new instance and return the id number&lt;br /&gt;
of the new instance.&lt;br /&gt;
The due data is added to the calendar.&lt;br /&gt;
This is common to all assignment types.&lt;br /&gt;
&lt;br /&gt;
== delete_instance (20) ==&lt;br /&gt;
Deletes an assignment activity&lt;br /&gt;
&lt;br /&gt;
Deletes all database records, files and calendar events for this newmodule.&lt;br /&gt;
This is common to all assignment types.&lt;br /&gt;
== update_instance (20) ==&lt;br /&gt;
Updates a new newmodule activity&lt;br /&gt;
&lt;br /&gt;
Given an object containing all the necessary data,&lt;br /&gt;
(defined by the form in mod.html) this function&lt;br /&gt;
will update the newmodule instance and return the id number&lt;br /&gt;
The due date is updated in the calendar&lt;br /&gt;
This is common to all assignment types.&lt;br /&gt;
== get_participants (19) ==&lt;br /&gt;
== user_complete (19) ==&lt;br /&gt;
Print complete information about the user&#039;s interaction with the newmodule&lt;br /&gt;
&lt;br /&gt;
== user_outline (19) ==&lt;br /&gt;
== get_post_actions (18) ==&lt;br /&gt;
== get_view_actions (18) ==&lt;br /&gt;
== cron (15) ==&lt;br /&gt;
== reset_userdata (12) ==&lt;br /&gt;
== print_recent_activity (11) ==&lt;br /&gt;
== reset_course_form_defaults (10) ==&lt;br /&gt;
== reset_course_form_definition (10) ==&lt;br /&gt;
== get_user_grades (8) ==&lt;br /&gt;
== grade_item_delete (8) ==&lt;br /&gt;
== grade_item_update (8) ==&lt;br /&gt;
== grades (8) ==&lt;br /&gt;
== update_grades (8) ==&lt;br /&gt;
== reset_gradebook (7) ==&lt;br /&gt;
== scale_used (7) ==&lt;br /&gt;
== scale_used_anywhere (6) ==&lt;br /&gt;
== get_recent_mod_activity (5) ==&lt;br /&gt;
== log_info (5) ==&lt;br /&gt;
== print_overview (5) ==&lt;br /&gt;
== print_recent_mod_activity (5) ==&lt;br /&gt;
== refresh_events (5) ==&lt;br /&gt;
== file_area (4) ==&lt;br /&gt;
== file_area_name (4) ==&lt;/div&gt;</summary>
		<author><name>Daniss</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Reference&amp;diff=34504</id>
		<title>Development:NEWMODULE Reference</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Reference&amp;diff=34504"/>
		<updated>2008-04-03T18:20:33Z</updated>

		<summary type="html">&lt;p&gt;Daniss: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[Development:NEWMODULE Documentation|NEWMODULE Documentation]] &amp;gt; Reference&lt;br /&gt;
----&lt;br /&gt;
{{Template:Work in progress}}&lt;br /&gt;
&lt;br /&gt;
This is a first draft of the list ot the functions more frequently used into Moodle modules. Between brakets the number of occurrences of each function in the following list of 20 modules: assignment, chat, choice, data, exercise, feedback, forum, glossary, hotpot, journal, label, lams, lesson, questionnaire, quiz, resource, scorm, survey, wiki, workshop.&lt;br /&gt;
&lt;br /&gt;
== add_instance (20) ==&lt;br /&gt;
Create a new newmodule activity&lt;br /&gt;
&lt;br /&gt;
Given an object containing all the necessary data,&lt;br /&gt;
(defined by the form in mod.html) this function&lt;br /&gt;
will create a new instance and return the id number&lt;br /&gt;
of the new instance.&lt;br /&gt;
The due data is added to the calendar.&lt;br /&gt;
This is common to all assignment types.&lt;br /&gt;
&lt;br /&gt;
== delete_instance (20) ==&lt;br /&gt;
Deletes an assignment activity&lt;br /&gt;
&lt;br /&gt;
Deletes all database records, files and calendar events for this newmodule.&lt;br /&gt;
This is common to all assignment types.&lt;br /&gt;
== update_instance (20) ==&lt;br /&gt;
Updates a new newmodule activity&lt;br /&gt;
&lt;br /&gt;
Given an object containing all the necessary data,&lt;br /&gt;
(defined by the form in mod.html) this function&lt;br /&gt;
will update the newmodule instance and return the id number&lt;br /&gt;
The due date is updated in the calendar&lt;br /&gt;
This is common to all assignment types.&lt;br /&gt;
== get_participants (19) ==&lt;br /&gt;
== user_complete (19) ==&lt;br /&gt;
== user_outline (19) ==&lt;br /&gt;
== get_post_actions (18) ==&lt;br /&gt;
== get_view_actions (18) ==&lt;br /&gt;
== cron (15) ==&lt;br /&gt;
== reset_userdata (12) ==&lt;br /&gt;
== print_recent_activity (11) ==&lt;br /&gt;
== reset_course_form_defaults (10) ==&lt;br /&gt;
== reset_course_form_definition (10) ==&lt;br /&gt;
== get_user_grades (8) ==&lt;br /&gt;
== grade_item_delete (8) ==&lt;br /&gt;
== grade_item_update (8) ==&lt;br /&gt;
== grades (8) ==&lt;br /&gt;
== update_grades (8) ==&lt;br /&gt;
== reset_gradebook (7) ==&lt;br /&gt;
== scale_used (7) ==&lt;br /&gt;
== scale_used_anywhere (6) ==&lt;br /&gt;
== get_recent_mod_activity (5) ==&lt;br /&gt;
== log_info (5) ==&lt;br /&gt;
== print_overview (5) ==&lt;br /&gt;
== print_recent_mod_activity (5) ==&lt;br /&gt;
== refresh_events (5) ==&lt;br /&gt;
== file_area (4) ==&lt;br /&gt;
== file_area_name (4) ==&lt;/div&gt;</summary>
		<author><name>Daniss</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Reference&amp;diff=34503</id>
		<title>Development:NEWMODULE Reference</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Reference&amp;diff=34503"/>
		<updated>2008-04-03T18:17:52Z</updated>

		<summary type="html">&lt;p&gt;Daniss: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[Development:NEWMODULE Documentation|NEWMODULE Documentation]] &amp;gt; Reference&lt;br /&gt;
----&lt;br /&gt;
{{Template:Work in progress}}&lt;br /&gt;
&lt;br /&gt;
This is a first draft of the list ot the functions more frequently used into Moodle modules. Between brakets the number of occurrences of each function in the following list of 20 modules: assignment, chat, choice, data, exercise, feedback, forum, glossary, hotpot, journal, label, lams, lesson, questionnaire, quiz, resource, scorm, survey, wiki, workshop.&lt;br /&gt;
&lt;br /&gt;
== add_instance (20) ==&lt;br /&gt;
Create a new newmodule activity&lt;br /&gt;
&lt;br /&gt;
Given an object containing all the necessary data,&lt;br /&gt;
(defined by the form in mod.html) this function&lt;br /&gt;
will create a new instance and return the id number&lt;br /&gt;
of the new instance.&lt;br /&gt;
The due data is added to the calendar&lt;br /&gt;
This is common to all assignment types.&lt;br /&gt;
&lt;br /&gt;
== delete_instance (20) ==&lt;br /&gt;
Deletes an assignment activity&lt;br /&gt;
&lt;br /&gt;
Deletes all database records, files and calendar events for this newmodule.&lt;br /&gt;
&lt;br /&gt;
== update_instance (20) ==&lt;br /&gt;
== get_participants (19) ==&lt;br /&gt;
== user_complete (19) ==&lt;br /&gt;
== user_outline (19) ==&lt;br /&gt;
== get_post_actions (18) ==&lt;br /&gt;
== get_view_actions (18) ==&lt;br /&gt;
== cron (15) ==&lt;br /&gt;
== reset_userdata (12) ==&lt;br /&gt;
== print_recent_activity (11) ==&lt;br /&gt;
== reset_course_form_defaults (10) ==&lt;br /&gt;
== reset_course_form_definition (10) ==&lt;br /&gt;
== get_user_grades (8) ==&lt;br /&gt;
== grade_item_delete (8) ==&lt;br /&gt;
== grade_item_update (8) ==&lt;br /&gt;
== grades (8) ==&lt;br /&gt;
== update_grades (8) ==&lt;br /&gt;
== reset_gradebook (7) ==&lt;br /&gt;
== scale_used (7) ==&lt;br /&gt;
== scale_used_anywhere (6) ==&lt;br /&gt;
== get_recent_mod_activity (5) ==&lt;br /&gt;
== log_info (5) ==&lt;br /&gt;
== print_overview (5) ==&lt;br /&gt;
== print_recent_mod_activity (5) ==&lt;br /&gt;
== refresh_events (5) ==&lt;br /&gt;
== file_area (4) ==&lt;br /&gt;
== file_area_name (4) ==&lt;/div&gt;</summary>
		<author><name>Daniss</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Reference&amp;diff=34502</id>
		<title>Development:NEWMODULE Reference</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Reference&amp;diff=34502"/>
		<updated>2008-04-03T18:16:59Z</updated>

		<summary type="html">&lt;p&gt;Daniss: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[Development:NEWMODULE Documentation|NEWMODULE Documentation]] &amp;gt; Reference&lt;br /&gt;
----&lt;br /&gt;
{{Template:Work in progress}}&lt;br /&gt;
&lt;br /&gt;
This is a first draft of the list ot the functions more frequently used into Moodle modules. Between brakets the number of occurrences of each function in the following list of 20 modules: assignment, chat, choice, data, exercise, feedback, forum, glossary, hotpot, journal, label, lams, lesson, questionnaire, quiz, resource, scorm, survey, wiki, workshop.&lt;br /&gt;
&lt;br /&gt;
== add_instance (20) ==&lt;br /&gt;
Create a new newmodule activity&lt;br /&gt;
&lt;br /&gt;
Given an object containing all the necessary data,&lt;br /&gt;
(defined by the form in mod.html) this function&lt;br /&gt;
will create a new instance and return the id number&lt;br /&gt;
of the new instance.&lt;br /&gt;
The due data is added to the calendar&lt;br /&gt;
This is common to all assignment types.&lt;br /&gt;
&lt;br /&gt;
== delete_instance (20) ==&lt;br /&gt;
Deletes an assignment activity&lt;br /&gt;
&lt;br /&gt;
Deletes all database records, files and calendar events for this assignment.&lt;br /&gt;
&lt;br /&gt;
== update_instance (20) ==&lt;br /&gt;
== get_participants (19) ==&lt;br /&gt;
== user_complete (19) ==&lt;br /&gt;
== user_outline (19) ==&lt;br /&gt;
== get_post_actions (18) ==&lt;br /&gt;
== get_view_actions (18) ==&lt;br /&gt;
== cron (15) ==&lt;br /&gt;
== reset_userdata (12) ==&lt;br /&gt;
== print_recent_activity (11) ==&lt;br /&gt;
== reset_course_form_defaults (10) ==&lt;br /&gt;
== reset_course_form_definition (10) ==&lt;br /&gt;
== get_user_grades (8) ==&lt;br /&gt;
== grade_item_delete (8) ==&lt;br /&gt;
== grade_item_update (8) ==&lt;br /&gt;
== grades (8) ==&lt;br /&gt;
== update_grades (8) ==&lt;br /&gt;
== reset_gradebook (7) ==&lt;br /&gt;
== scale_used (7) ==&lt;br /&gt;
== scale_used_anywhere (6) ==&lt;br /&gt;
== get_recent_mod_activity (5) ==&lt;br /&gt;
== log_info (5) ==&lt;br /&gt;
== print_overview (5) ==&lt;br /&gt;
== print_recent_mod_activity (5) ==&lt;br /&gt;
== refresh_events (5) ==&lt;br /&gt;
== file_area (4) ==&lt;br /&gt;
== file_area_name (4) ==&lt;/div&gt;</summary>
		<author><name>Daniss</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Reference&amp;diff=34501</id>
		<title>Development:NEWMODULE Reference</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Reference&amp;diff=34501"/>
		<updated>2008-04-03T18:15:55Z</updated>

		<summary type="html">&lt;p&gt;Daniss: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[Development:NEWMODULE Documentation|NEWMODULE Documentation]] &amp;gt; Reference&lt;br /&gt;
----&lt;br /&gt;
{{Template:Work in progress}}&lt;br /&gt;
&lt;br /&gt;
This is a first draft of the list ot the functions more frequently used into Moodle modules. Between brakets the number of occurrences of each function in the following list of 20 modules: assignment, chat, choice, data, exercise, feedback, forum, glossary, hotpot, journal, label, lams, lesson, questionnaire, quiz, resource, scorm, survey, wiki, workshop.&lt;br /&gt;
&lt;br /&gt;
*add_instance (20)&lt;br /&gt;
Create a new newmodule activity&lt;br /&gt;
&lt;br /&gt;
Given an object containing all the necessary data,&lt;br /&gt;
(defined by the form in mod.html) this function&lt;br /&gt;
will create a new instance and return the id number&lt;br /&gt;
of the new instance.&lt;br /&gt;
The due data is added to the calendar&lt;br /&gt;
This is common to all assignment types.&lt;br /&gt;
&lt;br /&gt;
== add_instance (20) ==&lt;br /&gt;
Create a new newmodule activity&lt;br /&gt;
&lt;br /&gt;
Given an object containing all the necessary data,&lt;br /&gt;
(defined by the form in mod.html) this function&lt;br /&gt;
will create a new instance and return the id number&lt;br /&gt;
of the new instance.&lt;br /&gt;
The due data is added to the calendar&lt;br /&gt;
This is common to all assignment types.&lt;br /&gt;
&lt;br /&gt;
== delete_instance (20) ==&lt;br /&gt;
Deletes an assignment activity&lt;br /&gt;
Deletes all database records, files and calendar events for this assignment.&lt;br /&gt;
&lt;br /&gt;
== update_instance (20) ==&lt;br /&gt;
== get_participants (19) ==&lt;br /&gt;
== user_complete (19) ==&lt;br /&gt;
== user_outline (19) ==&lt;br /&gt;
== get_post_actions (18) ==&lt;br /&gt;
== get_view_actions (18) ==&lt;br /&gt;
== cron (15) ==&lt;br /&gt;
== reset_userdata (12) ==&lt;br /&gt;
== print_recent_activity (11) ==&lt;br /&gt;
== reset_course_form_defaults (10) ==&lt;br /&gt;
== reset_course_form_definition (10) ==&lt;br /&gt;
== get_user_grades (8) ==&lt;br /&gt;
== grade_item_delete (8) ==&lt;br /&gt;
== grade_item_update (8) ==&lt;br /&gt;
== grades (8) ==&lt;br /&gt;
== update_grades (8) ==&lt;br /&gt;
== reset_gradebook (7) ==&lt;br /&gt;
== scale_used (7) ==&lt;br /&gt;
== scale_used_anywhere (6) ==&lt;br /&gt;
== get_recent_mod_activity (5) ==&lt;br /&gt;
== log_info (5) ==&lt;br /&gt;
== print_overview (5) ==&lt;br /&gt;
== print_recent_mod_activity (5) ==&lt;br /&gt;
== refresh_events (5) ==&lt;br /&gt;
== file_area (4) ==&lt;br /&gt;
== file_area_name (4) ==&lt;/div&gt;</summary>
		<author><name>Daniss</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Reference&amp;diff=34500</id>
		<title>Development:NEWMODULE Reference</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Reference&amp;diff=34500"/>
		<updated>2008-04-03T18:14:39Z</updated>

		<summary type="html">&lt;p&gt;Daniss: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[Development:NEWMODULE Documentation|NEWMODULE Documentation]] &amp;gt; Reference&lt;br /&gt;
----&lt;br /&gt;
{{Template:Work in progress}}&lt;br /&gt;
&lt;br /&gt;
This is a first draft of the list ot the functions more frequently used into Moodle modules. Between brakets the number of occurrences of each function in the following list of 20 modules: assignment, chat, choice, data, exercise, feedback, forum, glossary, hotpot, journal, label, lams, lesson, questionnaire, quiz, resource, scorm, survey, wiki, workshop.&lt;br /&gt;
&lt;br /&gt;
*add_instance (20)&lt;br /&gt;
Create a new newmodule activity&lt;br /&gt;
&lt;br /&gt;
Given an object containing all the necessary data,&lt;br /&gt;
(defined by the form in mod.html) this function&lt;br /&gt;
will create a new instance and return the id number&lt;br /&gt;
of the new instance.&lt;br /&gt;
The due data is added to the calendar&lt;br /&gt;
This is common to all assignment types.&lt;br /&gt;
&lt;br /&gt;
== add_instance (20) ==&lt;br /&gt;
Create a new newmodule activity&lt;br /&gt;
&lt;br /&gt;
Given an object containing all the necessary data,&lt;br /&gt;
(defined by the form in mod.html) this function&lt;br /&gt;
will create a new instance and return the id number&lt;br /&gt;
of the new instance.&lt;br /&gt;
The due data is added to the calendar&lt;br /&gt;
This is common to all assignment types.&lt;br /&gt;
&lt;br /&gt;
== delete_instance (20) ==&lt;br /&gt;
Deletes an assignment activity&lt;br /&gt;
     *&lt;br /&gt;
     * Deletes all database records, files and calendar events for this assignment.&lt;br /&gt;
     * @param $assignment object The assignment to be deleted&lt;br /&gt;
     * @return boolean False indicates error&lt;br /&gt;
&lt;br /&gt;
== update_instance (20) ==&lt;br /&gt;
== get_participants (19) ==&lt;br /&gt;
== user_complete (19) ==&lt;br /&gt;
== user_outline (19) ==&lt;br /&gt;
== get_post_actions (18) ==&lt;br /&gt;
== get_view_actions (18) ==&lt;br /&gt;
== cron (15) ==&lt;br /&gt;
== reset_userdata (12) ==&lt;br /&gt;
== print_recent_activity (11) ==&lt;br /&gt;
== reset_course_form_defaults (10) ==&lt;br /&gt;
== reset_course_form_definition (10) ==&lt;br /&gt;
== get_user_grades (8) ==&lt;br /&gt;
== grade_item_delete (8) ==&lt;br /&gt;
== grade_item_update (8) ==&lt;br /&gt;
== grades (8) ==&lt;br /&gt;
== update_grades (8) ==&lt;br /&gt;
== reset_gradebook (7) ==&lt;br /&gt;
== scale_used (7) ==&lt;br /&gt;
== scale_used_anywhere (6) ==&lt;br /&gt;
== get_recent_mod_activity (5) ==&lt;br /&gt;
== log_info (5) ==&lt;br /&gt;
== print_overview (5) ==&lt;br /&gt;
== print_recent_mod_activity (5) ==&lt;br /&gt;
== refresh_events (5) ==&lt;br /&gt;
== file_area (4) ==&lt;br /&gt;
== file_area_name (4) ==&lt;/div&gt;</summary>
		<author><name>Daniss</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Reference&amp;diff=34498</id>
		<title>Development:NEWMODULE Reference</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Reference&amp;diff=34498"/>
		<updated>2008-04-03T18:10:59Z</updated>

		<summary type="html">&lt;p&gt;Daniss: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[Development:NEWMODULE Documentation|NEWMODULE Documentation]] &amp;gt; Reference&lt;br /&gt;
----&lt;br /&gt;
{{Template:Work in progress}}&lt;br /&gt;
&lt;br /&gt;
This is a first draft of the list ot the functions more frequently used into Moodle modules. Between brakets the number of occurrences of each function in the following list of 20 modules: assignment, chat, choice, data, exercise, feedback, forum, glossary, hotpot, journal, label, lams, lesson, questionnaire, quiz, resource, scorm, survey, wiki, workshop.&lt;br /&gt;
&lt;br /&gt;
*add_instance (20)&lt;br /&gt;
Create a new newmodule activity&lt;br /&gt;
&lt;br /&gt;
Given an object containing all the necessary data,&lt;br /&gt;
(defined by the form in mod.html) this function&lt;br /&gt;
will create a new instance and return the id number&lt;br /&gt;
of the new instance.&lt;br /&gt;
The due data is added to the calendar&lt;br /&gt;
This is common to all assignment types.&lt;br /&gt;
&lt;br /&gt;
== delete_instance (20) ==&lt;br /&gt;
Create a new newmodule activity&lt;br /&gt;
&lt;br /&gt;
Given an object containing all the necessary data,&lt;br /&gt;
(defined by the form in mod.html) this function&lt;br /&gt;
will create a new instance and return the id number&lt;br /&gt;
of the new instance.&lt;br /&gt;
The due data is added to the calendar&lt;br /&gt;
This is common to all assignment types.&lt;br /&gt;
&lt;br /&gt;
== update_instance (20) ==&lt;br /&gt;
== get_participants (19) ==&lt;br /&gt;
== user_complete (19) ==&lt;br /&gt;
== user_outline (19) ==&lt;br /&gt;
== get_post_actions (18) ==&lt;br /&gt;
== get_view_actions (18) ==&lt;br /&gt;
== cron (15) ==&lt;br /&gt;
== reset_userdata (12) ==&lt;br /&gt;
== print_recent_activity (11) ==&lt;br /&gt;
== reset_course_form_defaults (10) ==&lt;br /&gt;
== reset_course_form_definition (10) ==&lt;br /&gt;
== get_user_grades (8) ==&lt;br /&gt;
== grade_item_delete (8) ==&lt;br /&gt;
== grade_item_update (8) ==&lt;br /&gt;
== grades (8) ==&lt;br /&gt;
== update_grades (8) ==&lt;br /&gt;
== reset_gradebook (7) ==&lt;br /&gt;
== scale_used (7) ==&lt;br /&gt;
== scale_used_anywhere (6) ==&lt;br /&gt;
== get_recent_mod_activity (5) ==&lt;br /&gt;
== log_info (5) ==&lt;br /&gt;
== print_overview (5) ==&lt;br /&gt;
== print_recent_mod_activity (5) ==&lt;br /&gt;
== refresh_events (5) ==&lt;br /&gt;
== file_area (4) ==&lt;br /&gt;
== file_area_name (4) ==&lt;br /&gt;
---&lt;br /&gt;
add_instance&#039;&#039;&#039;&amp;lt;br /&amp;gt;&lt;br /&gt;
---&lt;br /&gt;
delete_instance&amp;lt;br /&amp;gt;&lt;br /&gt;
---&lt;br /&gt;
update_instance&amp;lt;br /&amp;gt;&lt;br /&gt;
---&lt;br /&gt;
get_participants&amp;lt;br /&amp;gt;&lt;br /&gt;
---&lt;br /&gt;
user_complete&amp;lt;br /&amp;gt;&lt;br /&gt;
---&lt;br /&gt;
user_outline&amp;lt;br /&amp;gt;&lt;br /&gt;
---&lt;br /&gt;
get_post_actions&amp;lt;br /&amp;gt;&lt;br /&gt;
---&lt;br /&gt;
get_view_actions&amp;lt;br /&amp;gt;&lt;br /&gt;
---&lt;br /&gt;
cron&amp;lt;br /&amp;gt;&lt;br /&gt;
---&lt;br /&gt;
reset_userdata&amp;lt;br /&amp;gt;&lt;br /&gt;
---&lt;br /&gt;
print_recent_activity&amp;lt;br /&amp;gt;&lt;br /&gt;
---&lt;br /&gt;
reset_course_form_defaults&amp;lt;br /&amp;gt;&lt;br /&gt;
---&lt;br /&gt;
reset_course_form_definition&amp;lt;br /&amp;gt;&lt;br /&gt;
---&lt;br /&gt;
get_user_grades&amp;lt;br /&amp;gt;&lt;br /&gt;
---&lt;br /&gt;
grade_item_delete&amp;lt;br /&amp;gt;&lt;br /&gt;
---&lt;br /&gt;
grade_item_update&amp;lt;br /&amp;gt;&lt;br /&gt;
---&lt;br /&gt;
&#039;&#039;&#039;grades&#039;&#039;&#039;&amp;lt;br /&amp;gt;&lt;br /&gt;
---&lt;br /&gt;
&#039;&#039;&#039;update_grades&#039;&#039;&#039;&amp;lt;br /&amp;gt;&lt;br /&gt;
---&lt;br /&gt;
&#039;&#039;&#039;reset_gradebook&#039;&#039;&#039;&amp;lt;br /&amp;gt;&lt;br /&gt;
---&lt;br /&gt;
&#039;&#039;&#039;scale_used&#039;&#039;&#039;&amp;lt;br /&amp;gt;&lt;br /&gt;
---&lt;br /&gt;
&#039;&#039;&#039;scale_used_anywhere&#039;&#039;&#039;&amp;lt;br /&amp;gt;&lt;br /&gt;
---&lt;br /&gt;
&#039;&#039;&#039;get_recent_mod_activity&#039;&#039;&#039;&amp;lt;br /&amp;gt;&lt;br /&gt;
---&lt;br /&gt;
&#039;&#039;&#039;log_info&#039;&#039;&#039;&amp;lt;br /&amp;gt;&lt;br /&gt;
---&lt;br /&gt;
&#039;&#039;&#039;print_overview&#039;&#039;&#039;&amp;lt;br /&amp;gt;&lt;br /&gt;
---&lt;br /&gt;
&#039;&#039;&#039;print_recent_mod_activity&#039;&#039;&#039;&amp;lt;br /&amp;gt;&lt;br /&gt;
---&lt;br /&gt;
&#039;&#039;&#039;refresh_events&#039;&#039;&#039;&amp;lt;br /&amp;gt;&lt;br /&gt;
---&lt;br /&gt;
&#039;&#039;&#039;file_area&#039;&#039;&#039;&amp;lt;br /&amp;gt;&lt;br /&gt;
---&lt;br /&gt;
&#039;&#039;&#039;file_area_name&#039;&#039;&#039;&amp;lt;br /&amp;gt;&lt;br /&gt;
---&lt;/div&gt;</summary>
		<author><name>Daniss</name></author>
	</entry>
	<entry>
		<id>https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Reference&amp;diff=34497</id>
		<title>Development:NEWMODULE Reference</title>
		<link rel="alternate" type="text/html" href="https://docs.moodle.org/test/index.php?title=Development:NEWMODULE_Reference&amp;diff=34497"/>
		<updated>2008-04-03T18:06:02Z</updated>

		<summary type="html">&lt;p&gt;Daniss: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[Development:NEWMODULE Documentation|NEWMODULE Documentation]] &amp;gt; Reference&lt;br /&gt;
----&lt;br /&gt;
{{Template:Work in progress}}&lt;br /&gt;
&lt;br /&gt;
This is a first draft of the list ot the functions more frequently used into Moodle modules. Between brakets the number of occurrences of each function in the following list of 20 modules: assignment, chat, choice, data, exercise, feedback, forum, glossary, hotpot, journal, label, lams, lesson, questionnaire, quiz, resource, scorm, survey, wiki, workshop.&lt;br /&gt;
&lt;br /&gt;
*add_instance (20)&lt;br /&gt;
Create a new newmodule activity&lt;br /&gt;
&lt;br /&gt;
Given an object containing all the necessary data,&lt;br /&gt;
(defined by the form in mod.html) this function&lt;br /&gt;
will create a new instance and return the id number&lt;br /&gt;
of the new instance.&lt;br /&gt;
The due data is added to the calendar&lt;br /&gt;
This is common to all assignment types.&lt;br /&gt;
&lt;br /&gt;
*delete_instance (20)&lt;br /&gt;
*update_instance (20)&lt;br /&gt;
*get_participants (19)&lt;br /&gt;
*user_complete (19)&lt;br /&gt;
*user_outline (19)&lt;br /&gt;
*get_post_actions (18)&lt;br /&gt;
*get_view_actions (18)&lt;br /&gt;
*cron (15)&lt;br /&gt;
*reset_userdata (12)&lt;br /&gt;
*print_recent_activity (11)&lt;br /&gt;
*reset_course_form_defaults (10)&lt;br /&gt;
*reset_course_form_definition (10)&lt;br /&gt;
*get_user_grades (8)&lt;br /&gt;
*grade_item_delete (8)&lt;br /&gt;
*grade_item_update (8)&lt;br /&gt;
*grades (8)&lt;br /&gt;
*update_grades (8)&lt;br /&gt;
*reset_gradebook (7)&lt;br /&gt;
*scale_used (7)&lt;br /&gt;
*scale_used_anywhere (6)&lt;br /&gt;
*get_recent_mod_activity (5)&lt;br /&gt;
*log_info (5)&lt;br /&gt;
*print_overview (5)&lt;br /&gt;
*print_recent_mod_activity (5)&lt;br /&gt;
*refresh_events (5)&lt;br /&gt;
*file_area (4)&lt;br /&gt;
*file_area_name (4)&lt;br /&gt;
---&lt;br /&gt;
add_instance&#039;&#039;&#039;&amp;lt;br /&amp;gt;&lt;br /&gt;
Create a new newmodule activity&lt;br /&gt;
&lt;br /&gt;
Given an object containing all the necessary data,&lt;br /&gt;
(defined by the form in mod.html) this function&lt;br /&gt;
will create a new instance and return the id number&lt;br /&gt;
of the new instance.&lt;br /&gt;
The due data is added to the calendar&lt;br /&gt;
This is common to all assignment types.&lt;br /&gt;
---&lt;br /&gt;
delete_instance&amp;lt;br /&amp;gt;&lt;br /&gt;
---&lt;br /&gt;
update_instance&amp;lt;br /&amp;gt;&lt;br /&gt;
---&lt;br /&gt;
get_participants&amp;lt;br /&amp;gt;&lt;br /&gt;
---&lt;br /&gt;
user_complete&amp;lt;br /&amp;gt;&lt;br /&gt;
---&lt;br /&gt;
user_outline&amp;lt;br /&amp;gt;&lt;br /&gt;
---&lt;br /&gt;
get_post_actions&amp;lt;br /&amp;gt;&lt;br /&gt;
---&lt;br /&gt;
get_view_actions&amp;lt;br /&amp;gt;&lt;br /&gt;
---&lt;br /&gt;
cron&amp;lt;br /&amp;gt;&lt;br /&gt;
---&lt;br /&gt;
reset_userdata&amp;lt;br /&amp;gt;&lt;br /&gt;
---&lt;br /&gt;
print_recent_activity&amp;lt;br /&amp;gt;&lt;br /&gt;
---&lt;br /&gt;
reset_course_form_defaults&amp;lt;br /&amp;gt;&lt;br /&gt;
---&lt;br /&gt;
reset_course_form_definition&amp;lt;br /&amp;gt;&lt;br /&gt;
---&lt;br /&gt;
get_user_grades&amp;lt;br /&amp;gt;&lt;br /&gt;
---&lt;br /&gt;
grade_item_delete&amp;lt;br /&amp;gt;&lt;br /&gt;
---&lt;br /&gt;
grade_item_update&amp;lt;br /&amp;gt;&lt;br /&gt;
---&lt;br /&gt;
&#039;&#039;&#039;grades&#039;&#039;&#039;&amp;lt;br /&amp;gt;&lt;br /&gt;
---&lt;br /&gt;
&#039;&#039;&#039;update_grades&#039;&#039;&#039;&amp;lt;br /&amp;gt;&lt;br /&gt;
---&lt;br /&gt;
&#039;&#039;&#039;reset_gradebook&#039;&#039;&#039;&amp;lt;br /&amp;gt;&lt;br /&gt;
---&lt;br /&gt;
&#039;&#039;&#039;scale_used&#039;&#039;&#039;&amp;lt;br /&amp;gt;&lt;br /&gt;
---&lt;br /&gt;
&#039;&#039;&#039;scale_used_anywhere&#039;&#039;&#039;&amp;lt;br /&amp;gt;&lt;br /&gt;
---&lt;br /&gt;
&#039;&#039;&#039;get_recent_mod_activity&#039;&#039;&#039;&amp;lt;br /&amp;gt;&lt;br /&gt;
---&lt;br /&gt;
&#039;&#039;&#039;log_info&#039;&#039;&#039;&amp;lt;br /&amp;gt;&lt;br /&gt;
---&lt;br /&gt;
&#039;&#039;&#039;print_overview&#039;&#039;&#039;&amp;lt;br /&amp;gt;&lt;br /&gt;
---&lt;br /&gt;
&#039;&#039;&#039;print_recent_mod_activity&#039;&#039;&#039;&amp;lt;br /&amp;gt;&lt;br /&gt;
---&lt;br /&gt;
&#039;&#039;&#039;refresh_events&#039;&#039;&#039;&amp;lt;br /&amp;gt;&lt;br /&gt;
---&lt;br /&gt;
&#039;&#039;&#039;file_area&#039;&#039;&#039;&amp;lt;br /&amp;gt;&lt;br /&gt;
---&lt;br /&gt;
&#039;&#039;&#039;file_area_name&#039;&#039;&#039;&amp;lt;br /&amp;gt;&lt;br /&gt;
---&lt;/div&gt;</summary>
		<author><name>Daniss</name></author>
	</entry>
</feed>