This project does not seem to handle request data directly as such no vulnerable execution paths were found.
include
, or for example
via PHP's auto-loading mechanism.
These results are based on our legacy PHP analysis, consider migrating to our new PHP analysis engine instead. Learn more
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 | * @license GNU GPL 2 (http://www.gnu.org/licenses/old-licenses/gpl-2.0.html) |
||
12 | * @package alumni |
||
13 | * @since 2.6.0 |
||
14 | * @author John Mordo - jlm69 |
||
15 | */ |
||
16 | |||
17 | use Xmf\Request; |
||
18 | |||
19 | include __DIR__ . '/header.php'; |
||
20 | |||
21 | $xoops = Xoops::getInstance(); |
||
22 | $op = Request::getString('op', 'alumni_view'); |
||
23 | $xoops->header(); |
||
24 | $admin_page = new Xoops\Module\Admin(); |
||
0 ignored issues
–
show
|
|||
25 | $admin_page->displayNavigation('groupperm.php'); |
||
0 ignored issues
–
show
$admin_page does not seem to conform to the naming convention (^[a-z][a-zA-Z0-9]*$ ).
This check examines a number of code elements and verifies that they conform to the given naming conventions. You can set conventions for local variables, abstract classes, utility classes, constant, properties, methods, parameters, interfaces, classes, exceptions and special methods. ![]() |
|||
26 | $moduleId = $xoops->module->getVar('mid'); |
||
27 | $categoriesHandler = $xoops->getModuleHandler('category', 'alumni'); |
||
28 | $cats = $categoriesHandler->getAll(); |
||
29 | $cat_rows = $categoriesHandler->getCount(); |
||
0 ignored issues
–
show
$cat_rows does not seem to conform to the naming convention (^[a-z][a-zA-Z0-9]*$ ).
This check examines a number of code elements and verifies that they conform to the given naming conventions. You can set conventions for local variables, abstract classes, utility classes, constant, properties, methods, parameters, interfaces, classes, exceptions and special methods. ![]() |
|||
30 | |||
31 | include_once XOOPS_ROOT_PATH . "/modules/{$moduleDirName}/class/alumni_tree.php"; |
||
32 | $cattree = new AlumniObjectTree($cats, 'cid', 'pid'); |
||
33 | |||
34 | if ('0' == $cat_rows) { |
||
0 ignored issues
–
show
$cat_rows does not seem to conform to the naming convention (^[a-z][a-zA-Z0-9]*$ ).
This check examines a number of code elements and verifies that they conform to the given naming conventions. You can set conventions for local variables, abstract classes, utility classes, constant, properties, methods, parameters, interfaces, classes, exceptions and special methods. ![]() |
|||
35 | echo constant($modinfo_lang . '_MUST_ADD_CAT'); |
||
36 | } else { |
||
37 | $perm_desc = ''; |
||
0 ignored issues
–
show
$perm_desc does not seem to conform to the naming convention (^[a-z][a-zA-Z0-9]*$ ).
This check examines a number of code elements and verifies that they conform to the given naming conventions. You can set conventions for local variables, abstract classes, utility classes, constant, properties, methods, parameters, interfaces, classes, exceptions and special methods. ![]() |
|||
38 | switch ($op) { |
||
39 | |||
40 | case 'alumni_view': |
||
41 | View Code Duplication | default: |
|
0 ignored issues
–
show
This code seems to be duplicated across your project.
Duplicated code is one of the most pungent code smells. If you need to duplicate the same code in three or more different places, we strongly encourage you to look into extracting the code into a single class or operation. You can also find more detailed suggestions in the “Code” section of your repository. ![]() |
|||
42 | $title_of_form = constant($modinfo_lang . '_VIEWFORM'); |
||
0 ignored issues
–
show
$title_of_form does not seem to conform to the naming convention (^[a-z][a-zA-Z0-9]*$ ).
This check examines a number of code elements and verifies that they conform to the given naming conventions. You can set conventions for local variables, abstract classes, utility classes, constant, properties, methods, parameters, interfaces, classes, exceptions and special methods. ![]() |
|||
43 | $perm_name = 'alumni_view'; |
||
0 ignored issues
–
show
$perm_name does not seem to conform to the naming convention (^[a-z][a-zA-Z0-9]*$ ).
This check examines a number of code elements and verifies that they conform to the given naming conventions. You can set conventions for local variables, abstract classes, utility classes, constant, properties, methods, parameters, interfaces, classes, exceptions and special methods. ![]() |
|||
44 | $restriction = ''; |
||
45 | $anonymous = true; |
||
46 | $form = new XoopsGroupPermForm($title_of_form, $moduleId, $perm_name, $perm_desc, 'admin/groupperm.php', $anonymous); |
||
0 ignored issues
–
show
$title_of_form does not seem to conform to the naming convention (^[a-z][a-zA-Z0-9]*$ ).
This check examines a number of code elements and verifies that they conform to the given naming conventions. You can set conventions for local variables, abstract classes, utility classes, constant, properties, methods, parameters, interfaces, classes, exceptions and special methods. ![]() |
|||
47 | break; |
||
48 | |||
49 | case 'alumni_submit': |
||
50 | View Code Duplication | default: |
|
0 ignored issues
–
show
This code seems to be duplicated across your project.
Duplicated code is one of the most pungent code smells. If you need to duplicate the same code in three or more different places, we strongly encourage you to look into extracting the code into a single class or operation. You can also find more detailed suggestions in the “Code” section of your repository. ![]() |
|||
51 | $title_of_form = constant($modinfo_lang . '_SUBMITFORM'); |
||
0 ignored issues
–
show
$title_of_form does not seem to conform to the naming convention (^[a-z][a-zA-Z0-9]*$ ).
This check examines a number of code elements and verifies that they conform to the given naming conventions. You can set conventions for local variables, abstract classes, utility classes, constant, properties, methods, parameters, interfaces, classes, exceptions and special methods. ![]() |
|||
52 | $perm_name = 'alumni_submit'; |
||
0 ignored issues
–
show
$perm_name does not seem to conform to the naming convention (^[a-z][a-zA-Z0-9]*$ ).
This check examines a number of code elements and verifies that they conform to the given naming conventions. You can set conventions for local variables, abstract classes, utility classes, constant, properties, methods, parameters, interfaces, classes, exceptions and special methods. ![]() |
|||
53 | $restriction = ''; |
||
54 | $anonymous = false; |
||
55 | $form = new XoopsGroupPermForm($title_of_form, $moduleId, $perm_name, $perm_desc, 'admin/groupperm.php', $anonymous); |
||
0 ignored issues
–
show
$title_of_form does not seem to conform to the naming convention (^[a-z][a-zA-Z0-9]*$ ).
This check examines a number of code elements and verifies that they conform to the given naming conventions. You can set conventions for local variables, abstract classes, utility classes, constant, properties, methods, parameters, interfaces, classes, exceptions and special methods. ![]() |
|||
56 | break; |
||
57 | |||
58 | View Code Duplication | case 'alumni_premium': |
|
0 ignored issues
–
show
This code seems to be duplicated across your project.
Duplicated code is one of the most pungent code smells. If you need to duplicate the same code in three or more different places, we strongly encourage you to look into extracting the code into a single class or operation. You can also find more detailed suggestions in the “Code” section of your repository. ![]() |
|||
59 | $title_of_form = constant($modinfo_lang . '_PREMIUM'); |
||
0 ignored issues
–
show
$title_of_form does not seem to conform to the naming convention (^[a-z][a-zA-Z0-9]*$ ).
This check examines a number of code elements and verifies that they conform to the given naming conventions. You can set conventions for local variables, abstract classes, utility classes, constant, properties, methods, parameters, interfaces, classes, exceptions and special methods. ![]() |
|||
60 | $perm_name = 'alumni_premium'; |
||
0 ignored issues
–
show
$perm_name does not seem to conform to the naming convention (^[a-z][a-zA-Z0-9]*$ ).
This check examines a number of code elements and verifies that they conform to the given naming conventions. You can set conventions for local variables, abstract classes, utility classes, constant, properties, methods, parameters, interfaces, classes, exceptions and special methods. ![]() |
|||
61 | $restriction = ''; |
||
62 | $anonymous = false; |
||
63 | $form = new XoopsGroupPermForm($title_of_form, $moduleId, $perm_name, $perm_desc, 'admin/groupperm.php', $anonymous); |
||
0 ignored issues
–
show
$title_of_form does not seem to conform to the naming convention (^[a-z][a-zA-Z0-9]*$ ).
This check examines a number of code elements and verifies that they conform to the given naming conventions. You can set conventions for local variables, abstract classes, utility classes, constant, properties, methods, parameters, interfaces, classes, exceptions and special methods. ![]() |
|||
64 | break; |
||
65 | } |
||
66 | |||
67 | $opform = new XoopsSimpleForm('', 'opform', 'groupperm.php', 'get'); |
||
68 | $opSelect = new XoopsFormSelect('', 'op', $op); |
||
69 | $opSelect->setExtra('onchange="document.forms.opform.submit()"'); |
||
70 | $opSelect->addOption('alumni_view', constant($modinfo_lang . '_VIEWFORM')); |
||
71 | $opSelect->addOption('alumni_submit', constant($modinfo_lang . '_SUBMITFORM')); |
||
72 | $opSelect->addOption('alumni_premium', constant($modinfo_lang . '_PREMIUM')); |
||
73 | $opform->addElement($opSelect); |
||
74 | $opform->display(); |
||
75 | |||
76 | View Code Duplication | foreach (array_keys($cats) as $i) { |
|
0 ignored issues
–
show
This code seems to be duplicated across your project.
Duplicated code is one of the most pungent code smells. If you need to duplicate the same code in three or more different places, we strongly encourage you to look into extracting the code into a single class or operation. You can also find more detailed suggestions in the “Code” section of your repository. ![]() |
|||
77 | $cid = $cats[$i]->getVar('cid'); |
||
78 | $title = $cats[$i]->getVar('title'); |
||
79 | $pid = $cats[$i]->getVar('pid'); |
||
80 | $allcats = $cattree->alumni_makeArrayTree($cats[$i]->getVar('cid')); |
||
81 | $form->addItem($cid, $title, $pid); |
||
82 | } |
||
83 | $form->display(); |
||
84 | } |
||
85 | |||
86 | $xoops->footer(); |
||
87 |
This check examines a number of code elements and verifies that they conform to the given naming conventions.
You can set conventions for local variables, abstract classes, utility classes, constant, properties, methods, parameters, interfaces, classes, exceptions and special methods.