XOOPS
2.6.0
Main Page
Related Pages
Classes
Files
Examples
File List
File Members
modules.php
Go to the documentation of this file.
1
<?php
2
/*
3
You may not change or alter any portion of this comment or credits
4
of supporting developers from this source code or any supporting source code
5
which is considered copyrighted (c) material of the original comment or credit authors.
6
7
This program is distributed in the hope that it will be useful,
8
but WITHOUT ANY WARRANTY; without even the implied warranty of
9
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
10
*/
11
20
class
UserconfigsModulesForm
extends
Xoops\Form\ThemeForm
21
{
25
public
function
__construct
($obj = null)
26
{
27
}
28
32
public
function
getModulesForm
($mod = null)
33
{
34
$xoops
=
Xoops::getInstance
();
35
$mid
= 0;
36
if
($mod instanceof
XoopsModule
) {
37
$mid
= $mod->getVar(
'mid'
);
38
}
39
/* @var $plugin UserconfigsPluginInterface */
40
if
($plugins = \
Xoops
\Module\Plugin::getPlugins(
'userconfigs'
)) {
41
parent::__construct(
''
,
'pref_form'
,
'index.php'
,
'post'
,
true
,
'inline'
);
42
43
$ele =
new
Xoops\Form\Select
(
_MD_USERCONFIGS_CHOOSE_MODULE
,
'mid'
,
$mid
);
44
foreach
(array_keys($plugins) as
$dirname
) {
45
$mHelper =
$xoops
->getModuleHelper($dirname);
46
$ele->addOption($mHelper->getModule()->getVar(
'mid'
), $mHelper->getModule()->getVar(
'name'
));
47
}
48
$this->
addElement
($ele);
49
$this->
addElement
(
new
Xoops
\Form\Hidden(
'op'
,
'showmod'
));
50
$this->
addElement
(
new
Xoops
\Form\Button(
''
,
'button'
,
XoopsLocale::A_SUBMIT
,
'submit'
));
51
}
52
}
53
}
$mid
$mid
Definition:
index.php:39
XoopsLocaleEn_US\A_SUBMIT
const A_SUBMIT
Definition:
en_US.php:128
_MD_USERCONFIGS_CHOOSE_MODULE
const _MD_USERCONFIGS_CHOOSE_MODULE
Definition:
main.php:25
Xoops\getInstance
static getInstance()
Definition:
Xoops.php:160
UserconfigsModulesForm\getModulesForm
getModulesForm($mod=null)
Definition:
modules.php:32
Xoops\Form\Form\addElement
addElement(Element $formElement, $required=false)
Definition:
Form.php:206
UserconfigsModulesForm
Definition:
modules.php:20
Xoops\Form\ThemeForm
Definition:
ThemeForm.php:27
Xoops
$xoops
$xoops
Definition:
admin.php:25
XoopsModule
Definition:
module.php:31
UserconfigsModulesForm\__construct
__construct($obj=null)
Definition:
modules.php:25
$dirname
$dirname
Definition:
backend.php:38
Xoops\Form\Select
Definition:
Select.php:26
usr64
htdocs
modules
userconfigs
class
form
modules.php
Generated on Fri May 22 2015 03:07:04 for XOOPS by
1.8.9.1