<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="ru">
	<id>http://wiki.mipt.ru/index.php?action=history&amp;feed=atom&amp;title=Development%3ANEWMODULE_Tutorial</id>
	<title>Development:NEWMODULE Tutorial - История изменений</title>
	<link rel="self" type="application/atom+xml" href="http://wiki.mipt.ru/index.php?action=history&amp;feed=atom&amp;title=Development%3ANEWMODULE_Tutorial"/>
	<link rel="alternate" type="text/html" href="http://wiki.mipt.ru/index.php?title=Development:NEWMODULE_Tutorial&amp;action=history"/>
	<updated>2026-05-06T19:39:47Z</updated>
	<subtitle>История изменений этой страницы в вики</subtitle>
	<generator>MediaWiki 1.42.1</generator>
	<entry>
		<id>http://wiki.mipt.ru/index.php?title=Development:NEWMODULE_Tutorial&amp;diff=11462&amp;oldid=prev</id>
		<title>Олег Давидович: 1 версия импортирована</title>
		<link rel="alternate" type="text/html" href="http://wiki.mipt.ru/index.php?title=Development:NEWMODULE_Tutorial&amp;diff=11462&amp;oldid=prev"/>
		<updated>2024-10-21T08:52:50Z</updated>

		<summary type="html">&lt;p&gt;1 версия импортирована&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw=&quot;interface&quot;&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;ru&quot;&gt;
				&lt;td colspan=&quot;1&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;← Предыдущая версия&lt;/td&gt;
				&lt;td colspan=&quot;1&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;Версия от 08:52, 21 октября 2024&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-notice&quot; lang=&quot;ru&quot;&gt;&lt;div class=&quot;mw-diff-empty&quot;&gt;(нет различий)&lt;/div&gt;
&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;</summary>
		<author><name>Олег Давидович</name></author>
	</entry>
	<entry>
		<id>http://wiki.mipt.ru/index.php?title=Development:NEWMODULE_Tutorial&amp;diff=11461&amp;oldid=prev</id>
		<title>1&gt;Nakohdo: Moodle 1.9 template added</title>
		<link rel="alternate" type="text/html" href="http://wiki.mipt.ru/index.php?title=Development:NEWMODULE_Tutorial&amp;diff=11461&amp;oldid=prev"/>
		<updated>2011-03-08T18:10:37Z</updated>

		<summary type="html">&lt;p&gt;Moodle 1.9 template added&lt;/p&gt;
&lt;p&gt;&lt;b&gt;Новая страница&lt;/b&gt;&lt;/p&gt;&lt;div&gt;{{Template:Work in progress}}&lt;br /&gt;
{{New_Module}}&lt;br /&gt;
&lt;br /&gt;
{{Moodle 1.9}}&lt;br /&gt;
&lt;br /&gt;
== How to Begin the Creation of a New Module ==&lt;br /&gt;
&lt;br /&gt;
# Choose a name for your module. Take care: no capital letter and no numbers in the name. In this example it will be choosen: &amp;quot;widget&amp;quot;.&lt;br /&gt;
# Use a good text editor to perform a multi-file find/replace to change all occurrences of &amp;quot;newmodule&amp;quot; in each file with the name of your own module.&lt;br /&gt;
# Change the name of the folder containing your newly-created module to &amp;quot;widget&amp;quot;.&lt;br /&gt;
# Change the name of file &amp;quot;widget/lang/en_utf8/newmodule.php&amp;quot; to &amp;quot;widget.php&amp;quot;.&lt;br /&gt;
# Put your newly-created widget folder in moodle/mod/.&lt;br /&gt;
# Visit the Moodle &amp;quot;Notifications&amp;quot; page (in the Moodle-&amp;gt;Site Administration block) to trigger installation of your module.&lt;br /&gt;
# Follow the instructions on the screen.&lt;br /&gt;
&lt;br /&gt;
[[Image:widget.gif]]&lt;br /&gt;
&lt;br /&gt;
== Some Basic Regulation for the Beginner PHP Developer ==&lt;br /&gt;
&lt;br /&gt;
You will probably want to use this set of basic commands:&lt;br /&gt;
* require&lt;br /&gt;
* require_once &lt;br /&gt;
* include &lt;br /&gt;
* include_once &lt;br /&gt;
&lt;br /&gt;
Take in mind the difference between them.&amp;lt;br /&amp;gt;&lt;br /&gt;
* The difference between require and include is: &amp;#039;&amp;#039;&amp;#039;require&amp;#039;&amp;#039;&amp;#039; produces a fatal E_ERROR level error which halts execution if the specified file cannot be accessed, while &amp;#039;&amp;#039;&amp;#039;include&amp;#039;&amp;#039;&amp;#039; produces a warning (E_WARNING) which does not halt execution if the specified file cannot be accessed&amp;lt;br /&amp;gt;&lt;br /&gt;
* The difference between &amp;#039;&amp;#039;&amp;#039;require&amp;#039;&amp;#039;&amp;#039; and &amp;#039;&amp;#039;&amp;#039;require_once&amp;#039;&amp;#039;&amp;#039; is: &amp;#039;&amp;#039;&amp;#039;require_once&amp;#039;&amp;#039;&amp;#039; checks if the file has been included and does not include it again if it has&amp;lt;br /&amp;gt;&lt;br /&gt;
* The difference between &amp;#039;&amp;#039;&amp;#039;include&amp;#039;&amp;#039;&amp;#039; and &amp;#039;&amp;#039;&amp;#039;include_once&amp;#039;&amp;#039;&amp;#039; is: &amp;#039;&amp;#039;&amp;#039;include_once&amp;#039;&amp;#039;&amp;#039; checks if the file has been included and does not include it again if it has&amp;lt;br /&amp;gt;&lt;br /&gt;
Use only xxx to call libraries and use only xxx to include snippets of code written to different files.&amp;lt;br /&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Remember:&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;redirect&amp;#039;&amp;#039;&amp;#039; moves the execution of the code to the target file and you are allowed to call the target file passing it some parameters, for instance: &amp;lt;code php&amp;gt;redirect(&amp;quot;./come_modello/edit.php?id=$cm-&amp;gt;id&amp;quot;);&amp;lt;/code&amp;gt;&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;include&amp;#039;&amp;#039;&amp;#039; requires the name of the called file to be &amp;quot;clean&amp;quot; (i.e., without &amp;quot;?id=$cm-&amp;gt;id&amp;quot;), and the target file is executed as it were written in the place of the calling row.&lt;br /&gt;
&lt;br /&gt;
You need this information to correctly include library files into target files called through &amp;#039;&amp;#039;&amp;#039;redirect&amp;#039;&amp;#039;&amp;#039; or &amp;#039;&amp;#039;&amp;#039;include&amp;#039;&amp;#039;&amp;#039;.&lt;br /&gt;
&lt;br /&gt;
== See also: ==&lt;br /&gt;
* [[Development:Blocks|A Step-by-step Guide To Creating Blocks]] &lt;br /&gt;
&lt;br /&gt;
[[Category:Developer]]&lt;br /&gt;
[[Category:Tutorial|{{PAGENAME}}]]&lt;/div&gt;</summary>
		<author><name>1&gt;Nakohdo</name></author>
	</entry>
</feed>