This document explains the description of xoops_version.php for module developers.
xoops_version overview
xoops_version is a kind of manifesto of modules for Legacy. xoops_version is simply PHP file for quick parsing. This program file defines array '$modversion' which is parsed by Legacy. You must understand this reason. You can write code in your xoops_version.php, but Legacy doesn't vouch for its efficiency. Basically, you should write code to describe $mod_version only.
Some notes are here;
- You can reference documents in Japanese here.
$modversion['name']
A name of the module. This is must. You should use the constant which defines name for each languages.
$modversion['version']
A version number of the module. This is must. This value is converted to integer and stored to DB.
$storedVersion = (int)($modversion['version'] * 100);
Therefore, you must write a version with 'x.xx' format.
$modversion['version'] = '2.08';
The following examples are not handled correctly.
[BAD EXSAMPLES] $modversion['version'] = '1.0.2.1'; $modversion['version'] = '2.5 beta';
$modversion['description']
A simple description of the module. You should use the constant which defines name for each languages.
$modversion['licence']
A title of the module licence. Basically, this may be "GPL see LICENSE". But, if you supply the kernel for Cube layer, the module can contain another licence module. You may clear the licence in this information.
$modversion['help']
A file name of the help file, if it exists. Because this key has been reserved by XOOPS2 (But, it has never been used), you need another declaration to activate this information. That's the cube_style declaration.
$modversion['cube_style'] = true;
$modversion['official']
This is a deprecated information item in Legacy 2.1. All modules are unofficial, even if the module is developed by the dev team.
$modversion['image']
A icon file name of the module. You put the icon file to the 'images' directory of your module.
Page Info | |
---|---|
Page Name : | XOOPSCubeLegacy/Reference/xoops_version |
Page aliases : | None |
Page owner : | minahito |
Can Read | |
Groups : | All visitors |
Users : | All visitors |
Can Edit | |
Groups : | Registered Users |
Users : | No one |