1 |
efrain |
1 |
<h1>Example version.php file</h1>
|
|
|
2 |
|
|
|
3 |
<p>version.php is required for all plugins but themes.</p>
|
|
|
4 |
|
|
|
5 |
<h2>Example of values</h2>
|
|
|
6 |
|
|
|
7 |
<pre>
|
|
|
8 |
$plugin->version = 2011051000;
|
|
|
9 |
$plugin->requires = 2010112400;
|
|
|
10 |
$plugin->cron = 0;
|
|
|
11 |
$plugin->component = 'plugintype_pluginname';
|
|
|
12 |
$plugin->maturity = MATURITY_STABLE;
|
|
|
13 |
$plugin->release = '2.x (Build: 2011051000)';
|
|
|
14 |
$plugin->dependencies = array('mod_forum' => ANY_VERSION, 'mod_data' => 2010020300);
|
|
|
15 |
</pre>
|
|
|
16 |
|
|
|
17 |
Replace $plugin with $module for activity modules, as in
|
|
|
18 |
|
|
|
19 |
<pre>
|
|
|
20 |
$module->version = 2012122400;
|
|
|
21 |
</pre><?php // $Id$ $module->version = 1;
|
|
|
22 |
|
|
|
23 |
$plugin->component
|
|
|
24 |
= 'old_foobar';//$plugin->component='commented';
|
|
|
25 |
|
|
|
26 |
$plugin->component =
|
|
|
27 |
'block_foobar';
|
|
|
28 |
|
|
|
29 |
$plugin->version = 2013010100;
|
|
|
30 |
////////$plugin->version = 0;
|
|
|
31 |
/* for activity
|
|
|
32 |
modules use:
|
|
|
33 |
$module->version = 2014131300;
|
|
|
34 |
|
|
|
35 |
***/
|
|
|
36 |
$plugin->version = "2010091855"; // Do not use quotes here.
|
|
|
37 |
$plugin->version = '2010091856.9'; // Do not use quotes here.
|
|
|
38 |
|
|
|
39 |
|
|
|
40 |
$plugin->requires = /* 2012010100 */ 2012122401 ;
|
|
|
41 |
|
|
|
42 |
$module->maturity = MATURITY_STABLE;
|
|
|
43 |
$module->maturity = 50; // If both present, the constant wins (on contrary to what PHP would do)
|
|
|
44 |
$module->maturity = 'MATURITY_BETA'; // Do not use quotes here.
|
|
|
45 |
|
|
|
46 |
$plugin->maturity = 10;
|
|
|
47 |
$plugin->maturity = MATURITY_ALPHA;
|
|
|
48 |
|
|
|
49 |
|
|
|
50 |
|
|
|
51 |
$module->release = 2.3; $plugin->release = 'v2.4';
|
|
|
52 |
$module->release = "v2.3"; $plugin->release = 2.4;
|