Function b_system_admin_modules_show
has a Cognitive Complexity of 30 (exceeds 5 allowed). Consider refactoring. Open
function b_system_admin_modules_show() {
$block['mods'] = array();
$module_handler = icms::handler('icms_module');
$moduleperm_handler = icms::handler('icms_member_groupperm');
$criteria = new icms_db_criteria_Compo();
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Function b_system_admin_warnings_show
has a Cognitive Complexity of 26 (exceeds 5 allowed). Consider refactoring. Open
function b_system_admin_warnings_show() {
$block = array();
$block['msg'] = array();
// Check if PDO is being used - if not, issue a warning, because it is being removed from PHP
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Method b_system_admin_warnings_show
has 69 lines of code (exceeds 25 allowed). Consider refactoring. Open
function b_system_admin_warnings_show() {
$block = array();
$block['msg'] = array();
// Check if PDO is being used - if not, issue a warning, because it is being removed from PHP
Method b_system_admin_modules_show
has 57 lines of code (exceeds 25 allowed). Consider refactoring. Open
function b_system_admin_modules_show() {
$block['mods'] = array();
$module_handler = icms::handler('icms_module');
$moduleperm_handler = icms::handler('icms_member_groupperm');
$criteria = new icms_db_criteria_Compo();
Function b_system_admin_cp_new_show
has a Cognitive Complexity of 14 (exceeds 5 allowed). Consider refactoring. Open
function b_system_admin_cp_new_show() {
global $icmsTpl, $icmsConfig;
$block['lang_cp'] = _CPHOME;
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Function b_system_admin_cp_show
has a Cognitive Complexity of 14 (exceeds 5 allowed). Consider refactoring. Open
function b_system_admin_cp_show() {
global $icmsTpl, $icmsConfig;
$block['lang_cp'] = _CPHOME;
$block['lang_insmodules'] = _AD_INSTALLEDMODULES;
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Method b_system_admin_cp_new_show
has 38 lines of code (exceeds 25 allowed). Consider refactoring. Open
function b_system_admin_cp_new_show() {
global $icmsTpl, $icmsConfig;
$block['lang_cp'] = _CPHOME;
Method b_system_admin_cp_show
has 37 lines of code (exceeds 25 allowed). Consider refactoring. Open
function b_system_admin_cp_show() {
global $icmsTpl, $icmsConfig;
$block['lang_cp'] = _CPHOME;
$block['lang_insmodules'] = _AD_INSTALLEDMODULES;
The function b_system_admin_warnings_show() has an NPath complexity of 331776. The configured NPath complexity threshold is 200. Open
function b_system_admin_warnings_show() {
$block = array();
$block['msg'] = array();
// Check if PDO is being used - if not, issue a warning, because it is being removed from PHP
- Read upRead up
- Exclude checks
NPathComplexity
Since: 0.1
The NPath complexity of a method is the number of acyclic execution paths through that method. A threshold of 200 is generally considered the point where measures should be taken to reduce complexity.
Example
class Foo {
function bar() {
// lots of complicated code
}
}
Source https://phpmd.org/rules/codesize.html#npathcomplexity
The function b_system_admin_modules_show() has an NPath complexity of 10370. The configured NPath complexity threshold is 200. Open
function b_system_admin_modules_show() {
$block['mods'] = array();
$module_handler = icms::handler('icms_module');
$moduleperm_handler = icms::handler('icms_member_groupperm');
$criteria = new icms_db_criteria_Compo();
- Read upRead up
- Exclude checks
NPathComplexity
Since: 0.1
The NPath complexity of a method is the number of acyclic execution paths through that method. A threshold of 200 is generally considered the point where measures should be taken to reduce complexity.
Example
class Foo {
function bar() {
// lots of complicated code
}
}
Source https://phpmd.org/rules/codesize.html#npathcomplexity
The function b_system_admin_cp_show() has a Cyclomatic Complexity of 10. The configured cyclomatic complexity threshold is 10. Open
function b_system_admin_cp_show() {
global $icmsTpl, $icmsConfig;
$block['lang_cp'] = _CPHOME;
$block['lang_insmodules'] = _AD_INSTALLEDMODULES;
- Read upRead up
- Exclude checks
CyclomaticComplexity
Since: 0.1
Complexity is determined by the number of decision points in a method plus one for the method entry. The decision points are 'if', 'while', 'for', and 'case labels'. Generally, 1-4 is low complexity, 5-7 indicates moderate complexity, 8-10 is high complexity, and 11+ is very high complexity.
Example
// Cyclomatic Complexity = 11
class Foo {
1 public function example() {
2 if ($a == $b) {
3 if ($a1 == $b1) {
fiddle();
4 } elseif ($a2 == $b2) {
fiddle();
} else {
fiddle();
}
5 } elseif ($c == $d) {
6 while ($c == $d) {
fiddle();
}
7 } elseif ($e == $f) {
8 for ($n = 0; $n < $h; $n++) {
fiddle();
}
} else {
switch ($z) {
9 case 1:
fiddle();
break;
10 case 2:
fiddle();
break;
11 case 3:
fiddle();
break;
default:
fiddle();
break;
}
}
}
}
Source https://phpmd.org/rules/codesize.html#cyclomaticcomplexity
The function b_system_admin_modules_show() has a Cyclomatic Complexity of 20. The configured cyclomatic complexity threshold is 10. Open
function b_system_admin_modules_show() {
$block['mods'] = array();
$module_handler = icms::handler('icms_module');
$moduleperm_handler = icms::handler('icms_member_groupperm');
$criteria = new icms_db_criteria_Compo();
- Read upRead up
- Exclude checks
CyclomaticComplexity
Since: 0.1
Complexity is determined by the number of decision points in a method plus one for the method entry. The decision points are 'if', 'while', 'for', and 'case labels'. Generally, 1-4 is low complexity, 5-7 indicates moderate complexity, 8-10 is high complexity, and 11+ is very high complexity.
Example
// Cyclomatic Complexity = 11
class Foo {
1 public function example() {
2 if ($a == $b) {
3 if ($a1 == $b1) {
fiddle();
4 } elseif ($a2 == $b2) {
fiddle();
} else {
fiddle();
}
5 } elseif ($c == $d) {
6 while ($c == $d) {
fiddle();
}
7 } elseif ($e == $f) {
8 for ($n = 0; $n < $h; $n++) {
fiddle();
}
} else {
switch ($z) {
9 case 1:
fiddle();
break;
10 case 2:
fiddle();
break;
11 case 3:
fiddle();
break;
default:
fiddle();
break;
}
}
}
}
Source https://phpmd.org/rules/codesize.html#cyclomaticcomplexity
The function b_system_admin_warnings_show() has a Cyclomatic Complexity of 22. The configured cyclomatic complexity threshold is 10. Open
function b_system_admin_warnings_show() {
$block = array();
$block['msg'] = array();
// Check if PDO is being used - if not, issue a warning, because it is being removed from PHP
- Read upRead up
- Exclude checks
CyclomaticComplexity
Since: 0.1
Complexity is determined by the number of decision points in a method plus one for the method entry. The decision points are 'if', 'while', 'for', and 'case labels'. Generally, 1-4 is low complexity, 5-7 indicates moderate complexity, 8-10 is high complexity, and 11+ is very high complexity.
Example
// Cyclomatic Complexity = 11
class Foo {
1 public function example() {
2 if ($a == $b) {
3 if ($a1 == $b1) {
fiddle();
4 } elseif ($a2 == $b2) {
fiddle();
} else {
fiddle();
}
5 } elseif ($c == $d) {
6 while ($c == $d) {
fiddle();
}
7 } elseif ($e == $f) {
8 for ($n = 0; $n < $h; $n++) {
fiddle();
}
} else {
switch ($z) {
9 case 1:
fiddle();
break;
10 case 2:
fiddle();
break;
11 case 3:
fiddle();
break;
default:
fiddle();
break;
}
}
}
}
Source https://phpmd.org/rules/codesize.html#cyclomaticcomplexity
The function b_system_admin_cp_new_show() has a Cyclomatic Complexity of 10. The configured cyclomatic complexity threshold is 10. Open
function b_system_admin_cp_new_show() {
global $icmsTpl, $icmsConfig;
$block['lang_cp'] = _CPHOME;
- Read upRead up
- Exclude checks
CyclomaticComplexity
Since: 0.1
Complexity is determined by the number of decision points in a method plus one for the method entry. The decision points are 'if', 'while', 'for', and 'case labels'. Generally, 1-4 is low complexity, 5-7 indicates moderate complexity, 8-10 is high complexity, and 11+ is very high complexity.
Example
// Cyclomatic Complexity = 11
class Foo {
1 public function example() {
2 if ($a == $b) {
3 if ($a1 == $b1) {
fiddle();
4 } elseif ($a2 == $b2) {
fiddle();
} else {
fiddle();
}
5 } elseif ($c == $d) {
6 while ($c == $d) {
fiddle();
}
7 } elseif ($e == $f) {
8 for ($n = 0; $n < $h; $n++) {
fiddle();
}
} else {
switch ($z) {
9 case 1:
fiddle();
break;
10 case 2:
fiddle();
break;
11 case 3:
fiddle();
break;
default:
fiddle();
break;
}
}
}
}
Source https://phpmd.org/rules/codesize.html#cyclomaticcomplexity
Avoid using undefined variables such as '$modversion' which will lead to PHP notices. Open
unset($modversion);
- Read upRead up
- Exclude checks
UndefinedVariable
Since: 2.8.0
Detects when a variable is used that has not been defined before.
Example
class Foo
{
private function bar()
{
// $message is undefined
echo $message;
}
}
Source https://phpmd.org/rules/cleancode.html#undefinedvariable
Avoid using undefined variables such as '$modversion' which will lead to PHP notices. Open
if (FALSE != $all_ok || in_array($modversion['category'], $ok_syscats)) {
- Read upRead up
- Exclude checks
UndefinedVariable
Since: 2.8.0
Detects when a variable is used that has not been defined before.
Example
class Foo
{
private function bar()
{
// $message is undefined
echo $message;
}
}
Source https://phpmd.org/rules/cleancode.html#undefinedvariable
Avoid using undefined variables such as '$block' which will lead to PHP notices. Open
if (count($block['mods']) > 0) return $block;
- Read upRead up
- Exclude checks
UndefinedVariable
Since: 2.8.0
Detects when a variable is used that has not been defined before.
Example
class Foo
{
private function bar()
{
// $message is undefined
echo $message;
}
}
Source https://phpmd.org/rules/cleancode.html#undefinedvariable
Avoid using undefined variables such as '$modversion' which will lead to PHP notices. Open
$sysmod = array('title' => $modversion['name'], 'link' => ICMS_MODULES_URL . '/system/admin.php?fct=' . $file, 'image' => ICMS_MODULES_URL . '/system/admin/' . $file . '/images/' . $file . '_big.png');
- Read upRead up
- Exclude checks
UndefinedVariable
Since: 2.8.0
Detects when a variable is used that has not been defined before.
Example
class Foo
{
private function bar()
{
// $message is undefined
echo $message;
}
}
Source https://phpmd.org/rules/cleancode.html#undefinedvariable
Avoid using undefined variables such as '$modversion' which will lead to PHP notices. Open
if ($modversion['hasAdmin']) {
- Read upRead up
- Exclude checks
UndefinedVariable
Since: 2.8.0
Detects when a variable is used that has not been defined before.
Example
class Foo
{
private function bar()
{
// $message is undefined
echo $message;
}
}
Source https://phpmd.org/rules/cleancode.html#undefinedvariable
Avoid using undefined variables such as '$block' which will lead to PHP notices. Open
$block['mods'] = array();
- Read upRead up
- Exclude checks
UndefinedVariable
Since: 2.8.0
Detects when a variable is used that has not been defined before.
Example
class Foo
{
private function bar()
{
// $message is undefined
echo $message;
}
}
Source https://phpmd.org/rules/cleancode.html#undefinedvariable
Avoid using undefined variables such as '$modversion' which will lead to PHP notices. Open
$category = isset($modversion['category']) ? (int) ($modversion['category']) : 0;
- Read upRead up
- Exclude checks
UndefinedVariable
Since: 2.8.0
Detects when a variable is used that has not been defined before.
Example
class Foo
{
private function bar()
{
// $message is undefined
echo $message;
}
}
Source https://phpmd.org/rules/cleancode.html#undefinedvariable
Avoid using undefined variables such as '$modversion' which will lead to PHP notices. Open
$block[$modversion['group']][] = array('title' => $modversion['name'], 'link' => ICMS_MODULES_URL . '/system/admin.php?fct=' . $file, 'image' => ICMS_MODULES_URL . '/system/admin/' . $file . '/images/' . $file . '_big.png');
- Read upRead up
- Exclude checks
UndefinedVariable
Since: 2.8.0
Detects when a variable is used that has not been defined before.
Example
class Foo
{
private function bar()
{
// $message is undefined
echo $message;
}
}
Source https://phpmd.org/rules/cleancode.html#undefinedvariable
Avoid using undefined variables such as '$modversion' which will lead to PHP notices. Open
$block[$modversion['group']][] = array('title' => $modversion['name'], 'link' => ICMS_MODULES_URL . '/system/admin.php?fct=' . $file, 'image' => ICMS_MODULES_URL . '/system/admin/' . $file . '/images/' . $file . '_big.png');
- Read upRead up
- Exclude checks
UndefinedVariable
Since: 2.8.0
Detects when a variable is used that has not been defined before.
Example
class Foo
{
private function bar()
{
// $message is undefined
echo $message;
}
}
Source https://phpmd.org/rules/cleancode.html#undefinedvariable
Avoid using undefined variables such as '$block' which will lead to PHP notices. Open
$block['lang_insmodules'] = _AD_INSTALLEDMODULES;
- Read upRead up
- Exclude checks
UndefinedVariable
Since: 2.8.0
Detects when a variable is used that has not been defined before.
Example
class Foo
{
private function bar()
{
// $message is undefined
echo $message;
}
}
Source https://phpmd.org/rules/cleancode.html#undefinedvariable
Avoid using undefined variables such as '$modversion' which will lead to PHP notices. Open
if ($modversion['hasAdmin']) {
- Read upRead up
- Exclude checks
UndefinedVariable
Since: 2.8.0
Detects when a variable is used that has not been defined before.
Example
class Foo
{
private function bar()
{
// $message is undefined
echo $message;
}
}
Source https://phpmd.org/rules/cleancode.html#undefinedvariable
Avoid using undefined variables such as '$block' which will lead to PHP notices. Open
$block['lang_cp'] = _CPHOME;
- Read upRead up
- Exclude checks
UndefinedVariable
Since: 2.8.0
Detects when a variable is used that has not been defined before.
Example
class Foo
{
private function bar()
{
// $message is undefined
echo $message;
}
}
Source https://phpmd.org/rules/cleancode.html#undefinedvariable
Avoid using undefined variables such as '$block' which will lead to PHP notices. Open
if (count($block['sysmod']) > 0) return $block;
- Read upRead up
- Exclude checks
UndefinedVariable
Since: 2.8.0
Detects when a variable is used that has not been defined before.
Example
class Foo
{
private function bar()
{
// $message is undefined
echo $message;
}
}
Source https://phpmd.org/rules/cleancode.html#undefinedvariable
Avoid using undefined variables such as '$modversion' which will lead to PHP notices. Open
unset($modversion);
- Read upRead up
- Exclude checks
UndefinedVariable
Since: 2.8.0
Detects when a variable is used that has not been defined before.
Example
class Foo
{
private function bar()
{
// $message is undefined
echo $message;
}
}
Source https://phpmd.org/rules/cleancode.html#undefinedvariable
Avoid using undefined variables such as '$block' which will lead to PHP notices. Open
$block['sysmod'] = array();
- Read upRead up
- Exclude checks
UndefinedVariable
Since: 2.8.0
Detects when a variable is used that has not been defined before.
Example
class Foo
{
private function bar()
{
// $message is undefined
echo $message;
}
}
Source https://phpmd.org/rules/cleancode.html#undefinedvariable
Avoid using undefined variables such as '$modversion' which will lead to PHP notices. Open
if (FALSE != $all_ok || in_array($modversion['category'], $ok_syscats)) {
- Read upRead up
- Exclude checks
UndefinedVariable
Since: 2.8.0
Detects when a variable is used that has not been defined before.
Example
class Foo
{
private function bar()
{
// $message is undefined
echo $message;
}
}
Source https://phpmd.org/rules/cleancode.html#undefinedvariable
Avoid using undefined variables such as '$block' which will lead to PHP notices. Open
array_push($block['sysmod'], $sysmod);
- Read upRead up
- Exclude checks
UndefinedVariable
Since: 2.8.0
Detects when a variable is used that has not been defined before.
Example
class Foo
{
private function bar()
{
// $message is undefined
echo $message;
}
}
Source https://phpmd.org/rules/cleancode.html#undefinedvariable
Avoid using undefined variables such as '$block' which will lead to PHP notices. Open
if (count($block['sysmod']) > 0) return $block;
- Read upRead up
- Exclude checks
UndefinedVariable
Since: 2.8.0
Detects when a variable is used that has not been defined before.
Example
class Foo
{
private function bar()
{
// $message is undefined
echo $message;
}
}
Source https://phpmd.org/rules/cleancode.html#undefinedvariable
Avoid using undefined variables such as '$block' which will lead to PHP notices. Open
$block['mods'][] = $rtn;
- Read upRead up
- Exclude checks
UndefinedVariable
Since: 2.8.0
Detects when a variable is used that has not been defined before.
Example
class Foo
{
private function bar()
{
// $message is undefined
echo $message;
}
}
Source https://phpmd.org/rules/cleancode.html#undefinedvariable
Avoid using undefined variables such as '$modversion' which will lead to PHP notices. Open
$category = isset($modversion['category']) ? (int) ($modversion['category']) : 0;
- Read upRead up
- Exclude checks
UndefinedVariable
Since: 2.8.0
Detects when a variable is used that has not been defined before.
Example
class Foo
{
private function bar()
{
// $message is undefined
echo $message;
}
}
Source https://phpmd.org/rules/cleancode.html#undefinedvariable
Avoid using undefined variables such as '$modversion' which will lead to PHP notices. Open
$category = isset($modversion['category']) ? (int) ($modversion['category']) : 0;
- Read upRead up
- Exclude checks
UndefinedVariable
Since: 2.8.0
Detects when a variable is used that has not been defined before.
Example
class Foo
{
private function bar()
{
// $message is undefined
echo $message;
}
}
Source https://phpmd.org/rules/cleancode.html#undefinedvariable
Avoid using undefined variables such as '$block' which will lead to PHP notices. Open
if (count($block['mods']) > 0) return $block;
- Read upRead up
- Exclude checks
UndefinedVariable
Since: 2.8.0
Detects when a variable is used that has not been defined before.
Example
class Foo
{
private function bar()
{
// $message is undefined
echo $message;
}
}
Source https://phpmd.org/rules/cleancode.html#undefinedvariable
Avoid using undefined variables such as '$modversion' which will lead to PHP notices. Open
$category = isset($modversion['category']) ? (int) ($modversion['category']) : 0;
- Read upRead up
- Exclude checks
UndefinedVariable
Since: 2.8.0
Detects when a variable is used that has not been defined before.
Example
class Foo
{
private function bar()
{
// $message is undefined
echo $message;
}
}
Source https://phpmd.org/rules/cleancode.html#undefinedvariable
Missing class import via use statement (line '177', column '21'). Open
$criteria->add(new icms_db_criteria_Item('isactive', 1));
- Read upRead up
- Exclude checks
MissingImport
Since: 2.7.0
Importing all external classes in a file through use statements makes them clearly visible.
Example
function make() {
return new \stdClass();
}
Source http://phpmd.org/rules/cleancode.html#MissingImport
Missing class import via use statement (line '81', column '18'). Open
$criteria = new icms_db_criteria_Compo();
- Read upRead up
- Exclude checks
MissingImport
Since: 2.7.0
Importing all external classes in a file through use statements makes them clearly visible.
Example
function make() {
return new \stdClass();
}
Source http://phpmd.org/rules/cleancode.html#MissingImport
Missing class import via use statement (line '96', column '21'). Open
$criteria->add(new icms_db_criteria_Item('conf_value', 'tinymce'));
- Read upRead up
- Exclude checks
MissingImport
Since: 2.7.0
Importing all external classes in a file through use statements makes them clearly visible.
Example
function make() {
return new \stdClass();
}
Source http://phpmd.org/rules/cleancode.html#MissingImport
Missing class import via use statement (line '95', column '18'). Open
$criteria = new icms_db_criteria_Compo();
- Read upRead up
- Exclude checks
MissingImport
Since: 2.7.0
Importing all external classes in a file through use statements makes them clearly visible.
Example
function make() {
return new \stdClass();
}
Source http://phpmd.org/rules/cleancode.html#MissingImport
Missing class import via use statement (line '176', column '21'). Open
$criteria->add(new icms_db_criteria_Item('hasadmin', 1));
- Read upRead up
- Exclude checks
MissingImport
Since: 2.7.0
Importing all external classes in a file through use statements makes them clearly visible.
Example
function make() {
return new \stdClass();
}
Source http://phpmd.org/rules/cleancode.html#MissingImport
Missing class import via use statement (line '82', column '21'). Open
$criteria->add(new icms_db_criteria_Item('conf_value', 'FCKeditor'));
- Read upRead up
- Exclude checks
MissingImport
Since: 2.7.0
Importing all external classes in a file through use statements makes them clearly visible.
Example
function make() {
return new \stdClass();
}
Source http://phpmd.org/rules/cleancode.html#MissingImport
Missing class import via use statement (line '78', column '23'). Open
$editorhandler = new icms_plugins_EditorHandler();
- Read upRead up
- Exclude checks
MissingImport
Since: 2.7.0
Importing all external classes in a file through use statements makes them clearly visible.
Example
function make() {
return new \stdClass();
}
Source http://phpmd.org/rules/cleancode.html#MissingImport
Missing class import via use statement (line '175', column '18'). Open
$criteria = new icms_db_criteria_Compo();
- Read upRead up
- Exclude checks
MissingImport
Since: 2.7.0
Importing all external classes in a file through use statements makes them clearly visible.
Example
function make() {
return new \stdClass();
}
Source http://phpmd.org/rules/cleancode.html#MissingImport
Avoid using static access to class 'icms_core_Message' in method 'b_system_admin_warnings_show'. Open
array_push($block['msg'], icms_core_Message::error(_FCK_PRESENT_WARNING), '', false);
- Read upRead up
- Exclude checks
StaticAccess
Since: 1.4.0
Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.
Example
class Foo
{
public function bar()
{
Bar::baz();
}
}
Source https://phpmd.org/rules/cleancode.html#staticaccess
Avoid using static access to class 'icms' in method 'b_system_admin_cp_show'. Open
$sysperm_handler = icms::handler('icms_member_groupperm');
- Read upRead up
- Exclude checks
StaticAccess
Since: 1.4.0
Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.
Example
class Foo
{
public function bar()
{
Bar::baz();
}
}
Source https://phpmd.org/rules/cleancode.html#staticaccess
Avoid assigning values to variables in if clauses and the like (line '53', column '6'). Open
function b_system_admin_warnings_show() {
$block = array();
$block['msg'] = array();
// Check if PDO is being used - if not, issue a warning, because it is being removed from PHP
- Read upRead up
- Exclude checks
IfStatementAssignment
Since: 2.7.0
Assignments in if clauses and the like are considered a code smell. Assignments in PHP return the right operand as their result. In many cases, this is an expected behavior, but can lead to many difficult to spot bugs, especially when the right operand could result in zero, null or an empty string and the like.
Example
class Foo
{
public function bar($flag)
{
if ($foo = 'bar') { // possible typo
// ...
}
if ($baz = 0) { // always false
// ...
}
}
}
Source http://phpmd.org/rules/cleancode.html#ifstatementassignment
Avoid using static access to class 'icms_core_Message' in method 'b_system_admin_warnings_show'. Open
array_push($block['msg'], icms_core_Message::error('<a href="' . ICMS_MODULES_URL . '/system/admin.php?fct=modulesadmin&op=update&module=system">' . _WARNINGUPDATESYSTEM . '</a>'));
- Read upRead up
- Exclude checks
StaticAccess
Since: 1.4.0
Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.
Example
class Foo
{
public function bar()
{
Bar::baz();
}
}
Source https://phpmd.org/rules/cleancode.html#staticaccess
The method b_system_admin_cp_show uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them. Open
} else {
$groups = array();
}
- Read upRead up
- Exclude checks
ElseExpression
Since: 1.4.0
An if expression with an else branch is basically not necessary. You can rewrite the conditions in a way that the else clause is not necessary and the code becomes simpler to read. To achieve this, use early return statements, though you may need to split the code it several smaller methods. For very simple assignments you could also use the ternary operations.
Example
class Foo
{
public function bar($flag)
{
if ($flag) {
// one branch
} else {
// another branch
}
}
}
Source https://phpmd.org/rules/cleancode.html#elseexpression
Avoid using static access to class 'icms_core_Message' in method 'b_system_admin_warnings_show'. Open
array_push($block['msg'], icms_core_Message::error(_FCK_DEFAULT_WARNING), '', false);
- Read upRead up
- Exclude checks
StaticAccess
Since: 1.4.0
Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.
Example
class Foo
{
public function bar()
{
Bar::baz();
}
}
Source https://phpmd.org/rules/cleancode.html#staticaccess
Avoid using static access to class 'icms_core_Filesystem' in method 'b_system_admin_cp_show'. Open
$dirlist = icms_core_Filesystem::getDirList($admin_dir);
- Read upRead up
- Exclude checks
StaticAccess
Since: 1.4.0
Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.
Example
class Foo
{
public function bar()
{
Bar::baz();
}
}
Source https://phpmd.org/rules/cleancode.html#staticaccess
Avoid using static access to class 'icms' in method 'b_system_admin_modules_show'. Open
$module_handler = icms::handler('icms_module');
- Read upRead up
- Exclude checks
StaticAccess
Since: 1.4.0
Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.
Example
class Foo
{
public function bar()
{
Bar::baz();
}
}
Source https://phpmd.org/rules/cleancode.html#staticaccess
Avoid using static access to class 'icms_core_Message' in method 'b_system_admin_warnings_show'. Open
array_push($block['msg'], icms_core_Message::error(_CORE_MYSQL_DEPRECATED, '', FALSE));
- Read upRead up
- Exclude checks
StaticAccess
Since: 1.4.0
Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.
Example
class Foo
{
public function bar()
{
Bar::baz();
}
}
Source https://phpmd.org/rules/cleancode.html#staticaccess
Avoid using static access to class 'icms_core_Message' in method 'b_system_admin_warnings_show'. Open
if (!is_writable(ICMS_COMPILE_PATH)) array_push($block['msg'], icms_core_Message::warning(sprintf(_WARNINNOTWRITEABLE, ICMS_COMPILE_PATH)), '', FALSE);
- Read upRead up
- Exclude checks
StaticAccess
Since: 1.4.0
Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.
Example
class Foo
{
public function bar()
{
Bar::baz();
}
}
Source https://phpmd.org/rules/cleancode.html#staticaccess
Avoid using static access to class 'icms' in method 'b_system_admin_warnings_show'. Open
$config_handler = icms::handler('icms_config');
- Read upRead up
- Exclude checks
StaticAccess
Since: 1.4.0
Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.
Example
class Foo
{
public function bar()
{
Bar::baz();
}
}
Source https://phpmd.org/rules/cleancode.html#staticaccess
Avoid using static access to class 'icms_core_Message' in method 'b_system_admin_warnings_show'. Open
array_push($block['msg'], icms_core_Message::error(_TinyMCE_PRESENT_WARNING), '', false);
- Read upRead up
- Exclude checks
StaticAccess
Since: 1.4.0
Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.
Example
class Foo
{
public function bar()
{
Bar::baz();
}
}
Source https://phpmd.org/rules/cleancode.html#staticaccess
Avoid using static access to class 'icms_core_Message' in method 'b_system_admin_warnings_show'. Open
array_push($block['msg'], icms_core_Message::error(sprintf(_WARNINSTALL2, ICMS_ROOT_PATH . '/upgrade/'), '', FALSE));
- Read upRead up
- Exclude checks
StaticAccess
Since: 1.4.0
Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.
Example
class Foo
{
public function bar()
{
Bar::baz();
}
}
Source https://phpmd.org/rules/cleancode.html#staticaccess
The method b_system_admin_warnings_show uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them. Open
} else {
if (in_array('FCKeditor', array_flip($editorhandler->getList()))) {
array_push($block['msg'], icms_core_Message::error(_FCK_PRESENT_WARNING), '', false);
}
}
- Read upRead up
- Exclude checks
ElseExpression
Since: 1.4.0
An if expression with an else branch is basically not necessary. You can rewrite the conditions in a way that the else clause is not necessary and the code becomes simpler to read. To achieve this, use early return statements, though you may need to split the code it several smaller methods. For very simple assignments you could also use the ternary operations.
Example
class Foo
{
public function bar($flag)
{
if ($flag) {
// one branch
} else {
// another branch
}
}
}
Source https://phpmd.org/rules/cleancode.html#elseexpression
The method b_system_admin_warnings_show uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them. Open
} else {
if (in_array('tinymce', array_flip($editorhandler->getList()))) {
array_push($block['msg'], icms_core_Message::error(_TinyMCE_PRESENT_WARNING), '', false);
}
}
- Read upRead up
- Exclude checks
ElseExpression
Since: 1.4.0
An if expression with an else branch is basically not necessary. You can rewrite the conditions in a way that the else clause is not necessary and the code becomes simpler to read. To achieve this, use early return statements, though you may need to split the code it several smaller methods. For very simple assignments you could also use the ternary operations.
Example
class Foo
{
public function bar($flag)
{
if ($flag) {
// one branch
} else {
// another branch
}
}
}
Source https://phpmd.org/rules/cleancode.html#elseexpression
Avoid using static access to class 'icms' in method 'b_system_admin_cp_new_show'. Open
$sysperm_handler = icms::handler('icms_member_groupperm');
- Read upRead up
- Exclude checks
StaticAccess
Since: 1.4.0
Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.
Example
class Foo
{
public function bar()
{
Bar::baz();
}
}
Source https://phpmd.org/rules/cleancode.html#staticaccess
The method b_system_admin_modules_show uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them. Open
} else {
$rtn['hassubs'] = 0;
unset($rtn['subs']);
}
- Read upRead up
- Exclude checks
ElseExpression
Since: 1.4.0
An if expression with an else branch is basically not necessary. You can rewrite the conditions in a way that the else clause is not necessary and the code becomes simpler to read. To achieve this, use early return statements, though you may need to split the code it several smaller methods. For very simple assignments you could also use the ternary operations.
Example
class Foo
{
public function bar($flag)
{
if ($flag) {
// one branch
} else {
// another branch
}
}
}
Source https://phpmd.org/rules/cleancode.html#elseexpression
The method b_system_admin_cp_show uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them. Open
} else {
$all_ok = TRUE;
}
- Read upRead up
- Exclude checks
ElseExpression
Since: 1.4.0
An if expression with an else branch is basically not necessary. You can rewrite the conditions in a way that the else clause is not necessary and the code becomes simpler to read. To achieve this, use early return statements, though you may need to split the code it several smaller methods. For very simple assignments you could also use the ternary operations.
Example
class Foo
{
public function bar($flag)
{
if ($flag) {
// one branch
} else {
// another branch
}
}
}
Source https://phpmd.org/rules/cleancode.html#elseexpression
Avoid using static access to class 'icms_core_Message' in method 'b_system_admin_warnings_show'. Open
array_push($block['msg'], icms_core_Message::error(_TRUST_PATH_HELP));
- Read upRead up
- Exclude checks
StaticAccess
Since: 1.4.0
Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.
Example
class Foo
{
public function bar()
{
Bar::baz();
}
}
Source https://phpmd.org/rules/cleancode.html#staticaccess
Avoid using static access to class 'icms_core_Message' in method 'b_system_admin_warnings_show'. Open
array_push($block['msg'], icms_core_Message::error(_PROTECTOR_NOT_FOUND, '', FALSE));
- Read upRead up
- Exclude checks
StaticAccess
Since: 1.4.0
Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.
Example
class Foo
{
public function bar()
{
Bar::baz();
}
}
Source https://phpmd.org/rules/cleancode.html#staticaccess
Avoid using static access to class 'icms' in method 'b_system_admin_modules_show'. Open
$moduleperm_handler = icms::handler('icms_member_groupperm');
- Read upRead up
- Exclude checks
StaticAccess
Since: 1.4.0
Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.
Example
class Foo
{
public function bar()
{
Bar::baz();
}
}
Source https://phpmd.org/rules/cleancode.html#staticaccess
Avoid using static access to class 'icms_core_Filesystem' in method 'b_system_admin_cp_new_show'. Open
$dirlist = icms_core_Filesystem::getDirList($admin_dir);
- Read upRead up
- Exclude checks
StaticAccess
Since: 1.4.0
Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.
Example
class Foo
{
public function bar()
{
Bar::baz();
}
}
Source https://phpmd.org/rules/cleancode.html#staticaccess
Avoid using static access to class 'icms_core_Message' in method 'b_system_admin_warnings_show'. Open
array_push($block['msg'], icms_core_Message::error(sprintf(_WARNINSTALL2, ICMS_ROOT_PATH . '/install/'), '', FALSE));
- Read upRead up
- Exclude checks
StaticAccess
Since: 1.4.0
Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.
Example
class Foo
{
public function bar()
{
Bar::baz();
}
}
Source https://phpmd.org/rules/cleancode.html#staticaccess
Avoid using static access to class 'icms_core_Message' in method 'b_system_admin_warnings_show'. Open
array_push($block['msg'], icms_core_Message::error(sprintf(_WARNINWRITEABLE, ICMS_ROOT_PATH . '/mainfile.php'), '', FALSE));
- Read upRead up
- Exclude checks
StaticAccess
Since: 1.4.0
Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.
Example
class Foo
{
public function bar()
{
Bar::baz();
}
}
Source https://phpmd.org/rules/cleancode.html#staticaccess
Avoid using static access to class 'icms_core_Message' in method 'b_system_admin_warnings_show'. Open
if (!is_writable(ICMS_CACHE_PATH)) array_push($block['msg'], icms_core_Message::warning(sprintf(_WARNINNOTWRITEABLE, ICMS_CACHE_PATH)), '', FALSE);
- Read upRead up
- Exclude checks
StaticAccess
Since: 1.4.0
Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.
Example
class Foo
{
public function bar()
{
Bar::baz();
}
}
Source https://phpmd.org/rules/cleancode.html#staticaccess
The method b_system_admin_cp_new_show uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them. Open
} else {
$all_ok = TRUE;
}
- Read upRead up
- Exclude checks
ElseExpression
Since: 1.4.0
An if expression with an else branch is basically not necessary. You can rewrite the conditions in a way that the else clause is not necessary and the code becomes simpler to read. To achieve this, use early return statements, though you may need to split the code it several smaller methods. For very simple assignments you could also use the ternary operations.
Example
class Foo
{
public function bar($flag)
{
if ($flag) {
// one branch
} else {
// another branch
}
}
}
Source https://phpmd.org/rules/cleancode.html#elseexpression
Avoid using static access to class 'icms_core_Message' in method 'b_system_admin_warnings_show'. Open
array_push($block['msg'], icms_core_Message::error(sprintf(_CSSTIDY_VULN, 'plugins/csstidy/css_optimiser.php'), '', false));
- Read upRead up
- Exclude checks
StaticAccess
Since: 1.4.0
Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.
Example
class Foo
{
public function bar()
{
Bar::baz();
}
}
Source https://phpmd.org/rules/cleancode.html#staticaccess
Avoid using static access to class 'icms_core_Message' in method 'b_system_admin_warnings_show'. Open
array_push($block['msg'], icms_core_Message::error(_TinyMCE_DEFAULT_WARNING), '', false);
- Read upRead up
- Exclude checks
StaticAccess
Since: 1.4.0
Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.
Example
class Foo
{
public function bar()
{
Bar::baz();
}
}
Source https://phpmd.org/rules/cleancode.html#staticaccess
The method b_system_admin_modules_show uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them. Open
} else {
$rtn['hassubs'] = 0;
unset($rtn['subs']);
}
- Read upRead up
- Exclude checks
ElseExpression
Since: 1.4.0
An if expression with an else branch is basically not necessary. You can rewrite the conditions in a way that the else clause is not necessary and the code becomes simpler to read. To achieve this, use early return statements, though you may need to split the code it several smaller methods. For very simple assignments you could also use the ternary operations.
Example
class Foo
{
public function bar($flag)
{
if ($flag) {
// one branch
} else {
// another branch
}
}
}
Source https://phpmd.org/rules/cleancode.html#elseexpression
Avoid using static access to class 'icms_core_Message' in method 'b_system_admin_warnings_show'. Open
if (!is_writable(ICMS_UPLOAD_PATH)) array_push($block['msg'], icms_core_Message::warning(sprintf(_WARNINNOTWRITEABLE, ICMS_UPLOAD_PATH)), '', FALSE);
- Read upRead up
- Exclude checks
StaticAccess
Since: 1.4.0
Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.
Example
class Foo
{
public function bar()
{
Bar::baz();
}
}
Source https://phpmd.org/rules/cleancode.html#staticaccess
Avoid using static access to class 'icms_core_Message' in method 'b_system_admin_warnings_show'. Open
if (version_compare(phpversion(), '7.2', '<')) array_push($block['msg'], icms_core_Message::warning(sprintf(_OUTDATED_PHP, phpversion())), '', FALSE);
- Read upRead up
- Exclude checks
StaticAccess
Since: 1.4.0
Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.
Example
class Foo
{
public function bar()
{
Bar::baz();
}
}
Source https://phpmd.org/rules/cleancode.html#staticaccess
The method b_system_admin_cp_new_show uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them. Open
} else {
$groups = array();
}
- Read upRead up
- Exclude checks
ElseExpression
Since: 1.4.0
An if expression with an else branch is basically not necessary. You can rewrite the conditions in a way that the else clause is not necessary and the code becomes simpler to read. To achieve this, use early return statements, though you may need to split the code it several smaller methods. For very simple assignments you could also use the ternary operations.
Example
class Foo
{
public function bar($flag)
{
if ($flag) {
// one branch
} else {
// another branch
}
}
}
Source https://phpmd.org/rules/cleancode.html#elseexpression
Avoid unused local variables such as '$icmsTpl'. Open
global $icmsTpl, $icmsConfig;
- Read upRead up
- Exclude checks
UnusedLocalVariable
Since: 0.2
Detects when a local variable is declared and/or assigned, but not used.
Example
class Foo {
public function doSomething()
{
$i = 5; // Unused
}
}
Source https://phpmd.org/rules/unusedcode.html#unusedlocalvariable
Avoid unused local variables such as '$systemadm'. Open
$systemadm = TRUE;
- Read upRead up
- Exclude checks
UnusedLocalVariable
Since: 0.2
Detects when a local variable is declared and/or assigned, but not used.
Example
class Foo {
public function doSomething()
{
$i = 5; // Unused
}
}
Source https://phpmd.org/rules/unusedcode.html#unusedlocalvariable
Avoid unused local variables such as '$icmsTpl'. Open
global $icmsTpl, $icmsConfig;
- Read upRead up
- Exclude checks
UnusedLocalVariable
Since: 0.2
Detects when a local variable is declared and/or assigned, but not used.
Example
class Foo {
public function doSomething()
{
$i = 5; // Unused
}
}
Source https://phpmd.org/rules/unusedcode.html#unusedlocalvariable
Avoid unused local variables such as '$icmsConfig'. Open
global $icmsTpl, $icmsConfig;
- Read upRead up
- Exclude checks
UnusedLocalVariable
Since: 0.2
Detects when a local variable is declared and/or assigned, but not used.
Example
class Foo {
public function doSomething()
{
$i = 5; // Unused
}
}
Source https://phpmd.org/rules/unusedcode.html#unusedlocalvariable
Avoid unused local variables such as '$category'. Open
$category = isset($modversion['category']) ? (int) ($modversion['category']) : 0;
- Read upRead up
- Exclude checks
UnusedLocalVariable
Since: 0.2
Detects when a local variable is declared and/or assigned, but not used.
Example
class Foo {
public function doSomething()
{
$i = 5; // Unused
}
}
Source https://phpmd.org/rules/unusedcode.html#unusedlocalvariable
Avoid unused local variables such as '$icmsConfig'. Open
global $icmsTpl, $icmsConfig;
- Read upRead up
- Exclude checks
UnusedLocalVariable
Since: 0.2
Detects when a local variable is declared and/or assigned, but not used.
Example
class Foo {
public function doSomething()
{
$i = 5; // Unused
}
}
Source https://phpmd.org/rules/unusedcode.html#unusedlocalvariable
Avoid unused local variables such as '$category'. Open
$category = isset($modversion['category']) ? (int) ($modversion['category']) : 0;
- Read upRead up
- Exclude checks
UnusedLocalVariable
Since: 0.2
Detects when a local variable is declared and/or assigned, but not used.
Example
class Foo {
public function doSomething()
{
$i = 5; // Unused
}
}
Source https://phpmd.org/rules/unusedcode.html#unusedlocalvariable
Reference to static property xoopsDB
from undeclared class \icms
Open
$sql1 = "SELECT conf_modid FROM `" . icms::$xoopsDB->prefix('config') . "` WHERE conf_name = 'dos_skipmodules'";
- Exclude checks
Reference to undeclared constant \_CSSTIDY_VULN
Open
array_push($block['msg'], icms_core_Message::error(sprintf(_CSSTIDY_VULN, 'plugins/csstidy/css_optimiser.php'), '', false));
- Exclude checks
Reference to undeclared constant \_WARNINNOTWRITEABLE
Open
if (!is_writable(ICMS_COMPILE_PATH)) array_push($block['msg'], icms_core_Message::warning(sprintf(_WARNINNOTWRITEABLE, ICMS_COMPILE_PATH)), '', FALSE);
- Exclude checks
Reference to static property xoopsDB
from undeclared class \icms
Open
if (getDbValue(icms::$xoopsDB, 'modules', 'version', 'version="120" AND mid="1"') !== FALSE) {
- Exclude checks
Call to method error
from undeclared class \icms_core_Message
Open
array_push($block['msg'], icms_core_Message::error(sprintf(_WARNINWRITEABLE, ICMS_ROOT_PATH . '/mainfile.php'), '', FALSE));
- Exclude checks
Reference to static property xoopsDB
from undeclared class \icms
Open
if ($result1 = icms::$xoopsDB->query($sql1)) {
- Exclude checks
Reference to undeclared constant \_PROTECTOR_NOT_FOUND
Open
array_push($block['msg'], icms_core_Message::error(_PROTECTOR_NOT_FOUND, '', FALSE));
- Exclude checks
Call to method __construct
from undeclared class \icms_db_criteria_Compo
Open
$criteria = new icms_db_criteria_Compo();
- Exclude checks
Call to method getList
from undeclared class \icms_plugins_EditorHandler
Open
if (in_array('FCKeditor', array_flip($editorhandler->getList()))) {
- Exclude checks
Call to method setSort
from undeclared class \icms_db_criteria_Compo
Open
$criteria->setSort('mid');
- Exclude checks
Reference to static property xoopsDB
from undeclared class \icms
Open
list($modid) = icms::$xoopsDB->FetchRow($result1);
- Exclude checks
Call to method __construct
from undeclared class \icms_plugins_EditorHandler
Open
$editorhandler = new icms_plugins_EditorHandler();
- Exclude checks
Call to method __construct
from undeclared class \icms_db_criteria_Compo
Open
$criteria = new icms_db_criteria_Compo();
- Exclude checks
Call to method error
from undeclared class \icms_core_Message
Open
array_push($block['msg'], icms_core_Message::error(_CORE_MYSQL_DEPRECATED, '', FALSE));
- Exclude checks
Call to method error
from undeclared class \icms_core_Message
Open
array_push($block['msg'], icms_core_Message::error(_TinyMCE_PRESENT_WARNING), '', false);
- Exclude checks
Call to method handler
from undeclared class \icms
Open
$sysperm_handler = icms::handler('icms_member_groupperm');
- Exclude checks
Call to method error
from undeclared class \icms_core_Message
Open
array_push($block['msg'], icms_core_Message::error(_TRUST_PATH_HELP));
- Exclude checks
Reference to static property xoopsDB
from undeclared class \icms
Open
$sql2 = "SELECT isactive FROM `" . icms::$xoopsDB->prefix('modules') . "` WHERE mid =" . $modid;
- Exclude checks
Reference to static property xoopsDB
from undeclared class \icms
Open
list($protector_is_active) = icms::$xoopsDB->FetchRow($result2);
- Exclude checks
Reference to undeclared constant \_TinyMCE_DEFAULT_WARNING
Open
array_push($block['msg'], icms_core_Message::error(_TinyMCE_DEFAULT_WARNING), '', false);
- Exclude checks
Reference to undeclared constant \_PREFERENCES
Open
$subs = array('title' => _PREFERENCES, 'link' => ICMS_MODULES_URL . '/system/admin.php?fct=preferences&op=showmod&mod=' . $module->getVar('mid'));
- Exclude checks
Reference to undeclared constant \_TRUST_PATH_HELP
Open
array_push($block['msg'], icms_core_Message::error(_TRUST_PATH_HELP));
- Exclude checks
Call to method warning
from undeclared class \icms_core_Message
Open
if (!is_writable(ICMS_COMPILE_PATH)) array_push($block['msg'], icms_core_Message::warning(sprintf(_WARNINNOTWRITEABLE, ICMS_COMPILE_PATH)), '', FALSE);
- Exclude checks
Variable $block
was undeclared, but array fields are being added to it. Open
$block['lang_cp'] = _CPHOME;
- Exclude checks
Call to method error
from undeclared class \icms_core_Message
Open
array_push($block['msg'], icms_core_Message::error('<a href="' . ICMS_MODULES_URL . '/system/admin.php?fct=modulesadmin&op=update&module=system">' . _WARNINGUPDATESYSTEM . '</a>'));
- Exclude checks
Call to method error
from undeclared class \icms_core_Message
Open
array_push($block['msg'], icms_core_Message::error(sprintf(_CSSTIDY_VULN, 'plugins/csstidy/css_optimiser.php'), '', false));
- Exclude checks
Call to method error
from undeclared class \icms_core_Message
Open
array_push($block['msg'], icms_core_Message::error(_FCK_PRESENT_WARNING), '', false);
- Exclude checks
Reference to undeclared constant \_FCK_PRESENT_WARNING
Open
array_push($block['msg'], icms_core_Message::error(_FCK_PRESENT_WARNING), '', false);
- Exclude checks
Reference to static property user
from undeclared class \icms
Open
$groups = icms::$user->getGroups();
- Exclude checks
Call to method handler
from undeclared class \icms
Open
$sysperm_handler = icms::handler('icms_member_groupperm');
- Exclude checks
Reference to undeclared constant \_WARNINSTALL2
Open
array_push($block['msg'], icms_core_Message::error(sprintf(_WARNINSTALL2, ICMS_ROOT_PATH . '/install/'), '', FALSE));
- Exclude checks
Call to method handler
from undeclared class \icms
Open
$config_handler = icms::handler('icms_config');
- Exclude checks
Call to method __construct
from undeclared class \icms_db_criteria_Item
Open
$criteria->add(new icms_db_criteria_Item('conf_value', 'tinymce'));
- Exclude checks
Call to method add
from undeclared class \icms_db_criteria_Compo
Open
$criteria->add(new icms_db_criteria_Item('conf_value', 'tinymce'));
- Exclude checks
Variable $block
was undeclared, but array fields are being added to it. Open
$block['mods'] = array();
- Exclude checks
Reference to undeclared constant \_CPHOME
Open
$block['lang_cp'] = _CPHOME;
- Exclude checks
Reference to undeclared constant \_WARNINNOTWRITEABLE
Open
if (!is_writable(ICMS_UPLOAD_PATH)) array_push($block['msg'], icms_core_Message::warning(sprintf(_WARNINNOTWRITEABLE, ICMS_UPLOAD_PATH)), '', FALSE);
- Exclude checks
Call to method handler
from undeclared class \icms
Open
$module_handler = icms::handler('icms_module');
- Exclude checks
Call to method handler
from undeclared class \icms
Open
$moduleperm_handler = icms::handler('icms_member_groupperm');
- Exclude checks
Call to method add
from undeclared class \icms_db_criteria_Compo
Open
$criteria->add(new icms_db_criteria_Item('hasadmin', 1));
- Exclude checks
Reference to static property user
from undeclared class \icms
Open
$groups = icms::$user->getGroups();
- Exclude checks
Call to method getDirList
from undeclared class \icms_core_Filesystem
Open
$dirlist = icms_core_Filesystem::getDirList($admin_dir);
- Exclude checks
Call to method warning
from undeclared class \icms_core_Message
Open
if (version_compare(phpversion(), '7.2', '<')) array_push($block['msg'], icms_core_Message::warning(sprintf(_OUTDATED_PHP, phpversion())), '', FALSE);
- Exclude checks
Reference to undeclared constant \_TinyMCE_PRESENT_WARNING
Open
array_push($block['msg'], icms_core_Message::error(_TinyMCE_PRESENT_WARNING), '', false);
- Exclude checks
Reference to undeclared constant \_WARNINGUPDATESYSTEM
Open
array_push($block['msg'], icms_core_Message::error('<a href="' . ICMS_MODULES_URL . '/system/admin.php?fct=modulesadmin&op=update&module=system">' . _WARNINGUPDATESYSTEM . '</a>'));
- Exclude checks
Reference to static property xoopsDB
from undeclared class \icms
Open
$result2 = icms::$xoopsDB->query($sql2);
- Exclude checks
Reference to undeclared constant \_WARNINNOTWRITEABLE
Open
if (!is_writable(ICMS_CACHE_PATH)) array_push($block['msg'], icms_core_Message::warning(sprintf(_WARNINNOTWRITEABLE, ICMS_CACHE_PATH)), '', FALSE);
- Exclude checks
Reference to undeclared constant \_OUTDATED_PHP
Open
if (version_compare(phpversion(), '7.2', '<')) array_push($block['msg'], icms_core_Message::warning(sprintf(_OUTDATED_PHP, phpversion())), '', FALSE);
- Exclude checks
Call to method __construct
from undeclared class \icms_db_criteria_Item
Open
$criteria->add(new icms_db_criteria_Item('conf_value', 'FCKeditor'));
- Exclude checks
Reference to undeclared constant \_FCK_DEFAULT_WARNING
Open
array_push($block['msg'], icms_core_Message::error(_FCK_DEFAULT_WARNING), '', false);
- Exclude checks
Call to method error
from undeclared class \icms_core_Message
Open
array_push($block['msg'], icms_core_Message::error(_TinyMCE_DEFAULT_WARNING), '', false);
- Exclude checks
Call to method getList
from undeclared class \icms_plugins_EditorHandler
Open
if (in_array('tinymce', array_flip($editorhandler->getList()))) {
- Exclude checks
Call to method __construct
from undeclared class \icms_db_criteria_Item
Open
$criteria->add(new icms_db_criteria_Item('isactive', 1));
- Exclude checks
Call to method error
from undeclared class \icms_core_Message
Open
array_push($block['msg'], icms_core_Message::error(sprintf(_WARNINSTALL2, ICMS_ROOT_PATH . '/install/'), '', FALSE));
- Exclude checks
Reference to undeclared constant \_CPHOME
Open
$block['lang_cp'] = _CPHOME;
- Exclude checks
Variable $modversion
is undeclared Open
if ($modversion['hasAdmin']) {
- Exclude checks
Reference to undeclared constant \_WARNINWRITEABLE
Open
array_push($block['msg'], icms_core_Message::error(sprintf(_WARNINWRITEABLE, ICMS_ROOT_PATH . '/mainfile.php'), '', FALSE));
- Exclude checks
Reference to undeclared constant \_WARNINSTALL2
Open
array_push($block['msg'], icms_core_Message::error(sprintf(_WARNINSTALL2, ICMS_ROOT_PATH . '/upgrade/'), '', FALSE));
- Exclude checks
Call to method error
from undeclared class \icms_core_Message
Open
array_push($block['msg'], icms_core_Message::error(_PROTECTOR_NOT_FOUND, '', FALSE));
- Exclude checks
Reference to static property db
from undeclared class \icms
Open
if (icms::$db === NULL) {
- Exclude checks
Call to method warning
from undeclared class \icms_core_Message
Open
if (!is_writable(ICMS_CACHE_PATH)) array_push($block['msg'], icms_core_Message::warning(sprintf(_WARNINNOTWRITEABLE, ICMS_CACHE_PATH)), '', FALSE);
- Exclude checks
Call to method error
from undeclared class \icms_core_Message
Open
array_push($block['msg'], icms_core_Message::error(sprintf(_WARNINSTALL2, ICMS_ROOT_PATH . '/upgrade/'), '', FALSE));
- Exclude checks
Call to method add
from undeclared class \icms_db_criteria_Compo
Open
$criteria->add(new icms_db_criteria_Item('conf_value', 'FCKeditor'));
- Exclude checks
Call to method warning
from undeclared class \icms_core_Message
Open
if (!is_writable(ICMS_UPLOAD_PATH)) array_push($block['msg'], icms_core_Message::warning(sprintf(_WARNINNOTWRITEABLE, ICMS_UPLOAD_PATH)), '', FALSE);
- Exclude checks
Call to method __construct
from undeclared class \icms_db_criteria_Compo
Open
$criteria = new icms_db_criteria_Compo();
- Exclude checks
Reference to static property user
from undeclared class \icms
Open
if (is_object(icms::$user)) {
- Exclude checks
Call to method error
from undeclared class \icms_core_Message
Open
array_push($block['msg'], icms_core_Message::error(_FCK_DEFAULT_WARNING), '', false);
- Exclude checks
Reference to undeclared constant \_AD_INSTALLEDMODULES
Open
$block['lang_insmodules'] = _AD_INSTALLEDMODULES;
- Exclude checks
Reference to static property user
from undeclared class \icms
Open
if (is_object(icms::$user)) $admin_perm = $moduleperm_handler->checkRight('module_admin', $module->getVar('mid'), icms::$user->getGroups());
- Exclude checks
Argument 2 (haystack)
is null
but \in_array()
takes array
Open
if (FALSE != $all_ok || in_array($modversion['category'], $ok_syscats)) {
- Exclude checks
Variable $modversion
is undeclared Open
if ($modversion['hasAdmin']) {
- Exclude checks
Argument 2 (haystack)
is null
but \in_array()
takes array
Open
if (FALSE != $all_ok || in_array($modversion['category'], $ok_syscats)) {
- Exclude checks
Call to method __construct
from undeclared class \icms_db_criteria_Item
Open
$criteria->add(new icms_db_criteria_Item('hasadmin', 1));
- Exclude checks
Variable $block
was undeclared, but array fields are being added to it. Open
$block['lang_cp'] = _CPHOME;
- Exclude checks
Call to method getDirList
from undeclared class \icms_core_Filesystem
Open
$dirlist = icms_core_Filesystem::getDirList($admin_dir);
- Exclude checks
Call to method add
from undeclared class \icms_db_criteria_Compo
Open
$criteria->add(new icms_db_criteria_Item('isactive', 1));
- Exclude checks
Reference to static property user
from undeclared class \icms
Open
if (is_object(icms::$user)) {
- Exclude checks
Similar blocks of code found in 2 locations. Consider refactoring. Open
if ($confcount > 0) {
array_push($block['msg'], icms_core_Message::error(_TinyMCE_DEFAULT_WARNING), '', false);
} else {
if (in_array('tinymce', array_flip($editorhandler->getList()))) {
array_push($block['msg'], icms_core_Message::error(_TinyMCE_PRESENT_WARNING), '', false);
- Read upRead up
Duplicated Code
Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:
Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.
When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).
Tuning
This issue has a mass of 109.
We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.
The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.
If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.
See codeclimate-duplication
's documentation for more information about tuning the mass threshold in your .codeclimate.yml
.
Refactorings
- Extract Method
- Extract Class
- Form Template Method
- Introduce Null Object
- Pull Up Method
- Pull Up Field
- Substitute Algorithm
Further Reading
- Don't Repeat Yourself on the C2 Wiki
- Duplicated Code on SourceMaking
- Refactoring: Improving the Design of Existing Code by Martin Fowler. Duplicated Code, p76
Similar blocks of code found in 2 locations. Consider refactoring. Open
if ($confcount > 0) {
array_push($block['msg'], icms_core_Message::error(_FCK_DEFAULT_WARNING), '', false);
} else {
if (in_array('FCKeditor', array_flip($editorhandler->getList()))) {
array_push($block['msg'], icms_core_Message::error(_FCK_PRESENT_WARNING), '', false);
- Read upRead up
Duplicated Code
Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:
Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.
When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).
Tuning
This issue has a mass of 109.
We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.
The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.
If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.
See codeclimate-duplication
's documentation for more information about tuning the mass threshold in your .codeclimate.yml
.
Refactorings
- Extract Method
- Extract Class
- Form Template Method
- Introduce Null Object
- Pull Up Method
- Pull Up Field
- Substitute Algorithm
Further Reading
- Don't Repeat Yourself on the C2 Wiki
- Duplicated Code on SourceMaking
- Refactoring: Improving the Design of Existing Code by Martin Fowler. Duplicated Code, p76
TRUE, FALSE and NULL must be lowercase; expected "false" but found "FALSE" Open
if (getDbValue(icms::$xoopsDB, 'modules', 'version', 'version="120" AND mid="1"') !== FALSE) {
- Exclude checks
TRUE, FALSE and NULL must be lowercase; expected "true" but found "TRUE" Open
$all_ok = TRUE;
- Exclude checks
TRUE, FALSE and NULL must be lowercase; expected "false" but found "FALSE" Open
if (FALSE != $all_ok || in_array($modversion['category'], $ok_syscats)) {
- Exclude checks
TRUE, FALSE and NULL must be lowercase; expected "false" but found "FALSE" Open
array_push($block['msg'], icms_core_Message::error(_CORE_MYSQL_DEPRECATED, '', FALSE));
- Exclude checks
TRUE, FALSE and NULL must be lowercase; expected "false" but found "FALSE" Open
array_push($block['msg'], icms_core_Message::error(sprintf(_WARNINSTALL2, ICMS_ROOT_PATH . '/upgrade/'), '', FALSE));
- Exclude checks
TRUE, FALSE and NULL must be lowercase; expected "false" but found "FALSE" Open
if (!is_writable(ICMS_CACHE_PATH)) array_push($block['msg'], icms_core_Message::warning(sprintf(_WARNINNOTWRITEABLE, ICMS_CACHE_PATH)), '', FALSE);
- Exclude checks
TRUE, FALSE and NULL must be lowercase; expected "true" but found "TRUE" Open
$all_ok = TRUE;
- Exclude checks
TRUE, FALSE and NULL must be lowercase; expected "true" but found "TRUE" Open
$systemadm = TRUE;
- Exclude checks
TRUE, FALSE and NULL must be lowercase; expected "false" but found "FALSE" Open
if (FALSE != $all_ok || in_array($modversion['category'], $ok_syscats)) {
- Exclude checks
TRUE, FALSE and NULL must be lowercase; expected "false" but found "FALSE" Open
$all_ok = FALSE;
- Exclude checks
TRUE, FALSE and NULL must be lowercase; expected "null" but found "NULL" Open
if (NULL !== $modid) {
- Exclude checks
TRUE, FALSE and NULL must be lowercase; expected "false" but found "FALSE" Open
if (!is_writable(ICMS_COMPILE_PATH)) array_push($block['msg'], icms_core_Message::warning(sprintf(_WARNINNOTWRITEABLE, ICMS_COMPILE_PATH)), '', FALSE);
- Exclude checks
TRUE, FALSE and NULL must be lowercase; expected "null" but found "NULL" Open
if (icms::$db === NULL) {
- Exclude checks
TRUE, FALSE and NULL must be lowercase; expected "false" but found "FALSE" Open
array_push($block['msg'], icms_core_Message::error(sprintf(_WARNINSTALL2, ICMS_ROOT_PATH . '/install/'), '', FALSE));
- Exclude checks
TRUE, FALSE and NULL must be lowercase; expected "false" but found "FALSE" Open
if (version_compare(phpversion(), '7.2', '<')) array_push($block['msg'], icms_core_Message::warning(sprintf(_OUTDATED_PHP, phpversion())), '', FALSE);
- Exclude checks
TRUE, FALSE and NULL must be lowercase; expected "false" but found "FALSE" Open
array_push($block['msg'], icms_core_Message::error(sprintf(_WARNINWRITEABLE, ICMS_ROOT_PATH . '/mainfile.php'), '', FALSE));
- Exclude checks
TRUE, FALSE and NULL must be lowercase; expected "false" but found "FALSE" Open
if (!is_writable(ICMS_UPLOAD_PATH)) array_push($block['msg'], icms_core_Message::warning(sprintf(_WARNINNOTWRITEABLE, ICMS_UPLOAD_PATH)), '', FALSE);
- Exclude checks
TRUE, FALSE and NULL must be lowercase; expected "false" but found "FALSE" Open
array_push($block['msg'], icms_core_Message::error(_PROTECTOR_NOT_FOUND, '', FALSE));
- Exclude checks
TRUE, FALSE and NULL must be lowercase; expected "false" but found "FALSE" Open
$all_ok = FALSE;
- Exclude checks
Inline control structures are not allowed Open
if (count($block['sysmod']) > 0) return $block;
- Exclude checks
Inline control structures are not allowed Open
if (is_object(icms::$user)) $admin_perm = $moduleperm_handler->checkRight('module_admin', $module->getVar('mid'), icms::$user->getGroups());
- Exclude checks
Inline control structures are not allowed Open
if (count($block['mods']) > 0) return $block;
- Exclude checks
Inline control structures are not allowed Open
if (!is_writable(ICMS_CACHE_PATH)) array_push($block['msg'], icms_core_Message::warning(sprintf(_WARNINNOTWRITEABLE, ICMS_CACHE_PATH)), '', FALSE);
- Exclude checks
Inline control structures are not allowed Open
if (!is_writable(ICMS_UPLOAD_PATH)) array_push($block['msg'], icms_core_Message::warning(sprintf(_WARNINNOTWRITEABLE, ICMS_UPLOAD_PATH)), '', FALSE);
- Exclude checks
Inline control structures are not allowed Open
if (!is_writable(ICMS_COMPILE_PATH)) array_push($block['msg'], icms_core_Message::warning(sprintf(_WARNINNOTWRITEABLE, ICMS_COMPILE_PATH)), '', FALSE);
- Exclude checks
Inline control structures are not allowed Open
if (version_compare(phpversion(), '7.2', '<')) array_push($block['msg'], icms_core_Message::warning(sprintf(_OUTDATED_PHP, phpversion())), '', FALSE);
- Exclude checks
The variable $config_handler is not named in camelCase. Open
function b_system_admin_warnings_show() {
$block = array();
$block['msg'] = array();
// Check if PDO is being used - if not, issue a warning, because it is being removed from PHP
- Read upRead up
- Exclude checks
CamelCaseVariableName
Since: 0.2
It is considered best practice to use the camelCase notation to name variables.
Example
class ClassName {
public function doSomething() {
$data_module = new DataModule();
}
}
Source
The variable $config_handler is not named in camelCase. Open
function b_system_admin_warnings_show() {
$block = array();
$block['msg'] = array();
// Check if PDO is being used - if not, issue a warning, because it is being removed from PHP
- Read upRead up
- Exclude checks
CamelCaseVariableName
Since: 0.2
It is considered best practice to use the camelCase notation to name variables.
Example
class ClassName {
public function doSomething() {
$data_module = new DataModule();
}
}
Source
The variable $ok_syscats is not named in camelCase. Open
function b_system_admin_cp_show() {
global $icmsTpl, $icmsConfig;
$block['lang_cp'] = _CPHOME;
$block['lang_insmodules'] = _AD_INSTALLEDMODULES;
- Read upRead up
- Exclude checks
CamelCaseVariableName
Since: 0.2
It is considered best practice to use the camelCase notation to name variables.
Example
class ClassName {
public function doSomething() {
$data_module = new DataModule();
}
}
Source
The variable $admin_dir is not named in camelCase. Open
function b_system_admin_cp_show() {
global $icmsTpl, $icmsConfig;
$block['lang_cp'] = _CPHOME;
$block['lang_insmodules'] = _AD_INSTALLEDMODULES;
- Read upRead up
- Exclude checks
CamelCaseVariableName
Since: 0.2
It is considered best practice to use the camelCase notation to name variables.
Example
class ClassName {
public function doSomething() {
$data_module = new DataModule();
}
}
Source
The variable $moduleperm_handler is not named in camelCase. Open
function b_system_admin_modules_show() {
$block['mods'] = array();
$module_handler = icms::handler('icms_module');
$moduleperm_handler = icms::handler('icms_member_groupperm');
$criteria = new icms_db_criteria_Compo();
- Read upRead up
- Exclude checks
CamelCaseVariableName
Since: 0.2
It is considered best practice to use the camelCase notation to name variables.
Example
class ClassName {
public function doSomething() {
$data_module = new DataModule();
}
}
Source
The variable $moduleperm_handler is not named in camelCase. Open
function b_system_admin_modules_show() {
$block['mods'] = array();
$module_handler = icms::handler('icms_module');
$moduleperm_handler = icms::handler('icms_member_groupperm');
$criteria = new icms_db_criteria_Compo();
- Read upRead up
- Exclude checks
CamelCaseVariableName
Since: 0.2
It is considered best practice to use the camelCase notation to name variables.
Example
class ClassName {
public function doSomething() {
$data_module = new DataModule();
}
}
Source
The variable $ok_syscats is not named in camelCase. Open
function b_system_admin_cp_new_show() {
global $icmsTpl, $icmsConfig;
$block['lang_cp'] = _CPHOME;
- Read upRead up
- Exclude checks
CamelCaseVariableName
Since: 0.2
It is considered best practice to use the camelCase notation to name variables.
Example
class ClassName {
public function doSomething() {
$data_module = new DataModule();
}
}
Source
The variable $protector_is_active is not named in camelCase. Open
function b_system_admin_warnings_show() {
$block = array();
$block['msg'] = array();
// Check if PDO is being used - if not, issue a warning, because it is being removed from PHP
- Read upRead up
- Exclude checks
CamelCaseVariableName
Since: 0.2
It is considered best practice to use the camelCase notation to name variables.
Example
class ClassName {
public function doSomething() {
$data_module = new DataModule();
}
}
Source
The variable $ok_syscats is not named in camelCase. Open
function b_system_admin_cp_show() {
global $icmsTpl, $icmsConfig;
$block['lang_cp'] = _CPHOME;
$block['lang_insmodules'] = _AD_INSTALLEDMODULES;
- Read upRead up
- Exclude checks
CamelCaseVariableName
Since: 0.2
It is considered best practice to use the camelCase notation to name variables.
Example
class ClassName {
public function doSomething() {
$data_module = new DataModule();
}
}
Source
The variable $all_ok is not named in camelCase. Open
function b_system_admin_cp_new_show() {
global $icmsTpl, $icmsConfig;
$block['lang_cp'] = _CPHOME;
- Read upRead up
- Exclude checks
CamelCaseVariableName
Since: 0.2
It is considered best practice to use the camelCase notation to name variables.
Example
class ClassName {
public function doSomething() {
$data_module = new DataModule();
}
}
Source
The variable $all_ok is not named in camelCase. Open
function b_system_admin_cp_new_show() {
global $icmsTpl, $icmsConfig;
$block['lang_cp'] = _CPHOME;
- Read upRead up
- Exclude checks
CamelCaseVariableName
Since: 0.2
It is considered best practice to use the camelCase notation to name variables.
Example
class ClassName {
public function doSomething() {
$data_module = new DataModule();
}
}
Source
The variable $module_handler is not named in camelCase. Open
function b_system_admin_modules_show() {
$block['mods'] = array();
$module_handler = icms::handler('icms_module');
$moduleperm_handler = icms::handler('icms_member_groupperm');
$criteria = new icms_db_criteria_Compo();
- Read upRead up
- Exclude checks
CamelCaseVariableName
Since: 0.2
It is considered best practice to use the camelCase notation to name variables.
Example
class ClassName {
public function doSomething() {
$data_module = new DataModule();
}
}
Source
The variable $admin_dir is not named in camelCase. Open
function b_system_admin_cp_new_show() {
global $icmsTpl, $icmsConfig;
$block['lang_cp'] = _CPHOME;
- Read upRead up
- Exclude checks
CamelCaseVariableName
Since: 0.2
It is considered best practice to use the camelCase notation to name variables.
Example
class ClassName {
public function doSomething() {
$data_module = new DataModule();
}
}
Source
The variable $ok_syscats is not named in camelCase. Open
function b_system_admin_cp_new_show() {
global $icmsTpl, $icmsConfig;
$block['lang_cp'] = _CPHOME;
- Read upRead up
- Exclude checks
CamelCaseVariableName
Since: 0.2
It is considered best practice to use the camelCase notation to name variables.
Example
class ClassName {
public function doSomething() {
$data_module = new DataModule();
}
}
Source
The variable $admin_perm is not named in camelCase. Open
function b_system_admin_modules_show() {
$block['mods'] = array();
$module_handler = icms::handler('icms_module');
$moduleperm_handler = icms::handler('icms_member_groupperm');
$criteria = new icms_db_criteria_Compo();
- Read upRead up
- Exclude checks
CamelCaseVariableName
Since: 0.2
It is considered best practice to use the camelCase notation to name variables.
Example
class ClassName {
public function doSomething() {
$data_module = new DataModule();
}
}
Source
The variable $sysperm_handler is not named in camelCase. Open
function b_system_admin_cp_show() {
global $icmsTpl, $icmsConfig;
$block['lang_cp'] = _CPHOME;
$block['lang_insmodules'] = _AD_INSTALLEDMODULES;
- Read upRead up
- Exclude checks
CamelCaseVariableName
Since: 0.2
It is considered best practice to use the camelCase notation to name variables.
Example
class ClassName {
public function doSomething() {
$data_module = new DataModule();
}
}
Source
The variable $admin_dir is not named in camelCase. Open
function b_system_admin_cp_show() {
global $icmsTpl, $icmsConfig;
$block['lang_cp'] = _CPHOME;
$block['lang_insmodules'] = _AD_INSTALLEDMODULES;
- Read upRead up
- Exclude checks
CamelCaseVariableName
Since: 0.2
It is considered best practice to use the camelCase notation to name variables.
Example
class ClassName {
public function doSomething() {
$data_module = new DataModule();
}
}
Source
The variable $mod_version_file is not named in camelCase. Open
function b_system_admin_cp_show() {
global $icmsTpl, $icmsConfig;
$block['lang_cp'] = _CPHOME;
$block['lang_insmodules'] = _AD_INSTALLEDMODULES;
- Read upRead up
- Exclude checks
CamelCaseVariableName
Since: 0.2
It is considered best practice to use the camelCase notation to name variables.
Example
class ClassName {
public function doSomething() {
$data_module = new DataModule();
}
}
Source
The variable $all_ok is not named in camelCase. Open
function b_system_admin_cp_show() {
global $icmsTpl, $icmsConfig;
$block['lang_cp'] = _CPHOME;
$block['lang_insmodules'] = _AD_INSTALLEDMODULES;
- Read upRead up
- Exclude checks
CamelCaseVariableName
Since: 0.2
It is considered best practice to use the camelCase notation to name variables.
Example
class ClassName {
public function doSomething() {
$data_module = new DataModule();
}
}
Source
The variable $admin_dir is not named in camelCase. Open
function b_system_admin_cp_show() {
global $icmsTpl, $icmsConfig;
$block['lang_cp'] = _CPHOME;
$block['lang_insmodules'] = _AD_INSTALLEDMODULES;
- Read upRead up
- Exclude checks
CamelCaseVariableName
Since: 0.2
It is considered best practice to use the camelCase notation to name variables.
Example
class ClassName {
public function doSomething() {
$data_module = new DataModule();
}
}
Source
The variable $mod_version_file is not named in camelCase. Open
function b_system_admin_cp_new_show() {
global $icmsTpl, $icmsConfig;
$block['lang_cp'] = _CPHOME;
- Read upRead up
- Exclude checks
CamelCaseVariableName
Since: 0.2
It is considered best practice to use the camelCase notation to name variables.
Example
class ClassName {
public function doSomething() {
$data_module = new DataModule();
}
}
Source
The variable $sysperm_handler is not named in camelCase. Open
function b_system_admin_cp_new_show() {
global $icmsTpl, $icmsConfig;
$block['lang_cp'] = _CPHOME;
- Read upRead up
- Exclude checks
CamelCaseVariableName
Since: 0.2
It is considered best practice to use the camelCase notation to name variables.
Example
class ClassName {
public function doSomething() {
$data_module = new DataModule();
}
}
Source
The variable $admin_dir is not named in camelCase. Open
function b_system_admin_cp_new_show() {
global $icmsTpl, $icmsConfig;
$block['lang_cp'] = _CPHOME;
- Read upRead up
- Exclude checks
CamelCaseVariableName
Since: 0.2
It is considered best practice to use the camelCase notation to name variables.
Example
class ClassName {
public function doSomething() {
$data_module = new DataModule();
}
}
Source
The variable $admin_dir is not named in camelCase. Open
function b_system_admin_cp_show() {
global $icmsTpl, $icmsConfig;
$block['lang_cp'] = _CPHOME;
$block['lang_insmodules'] = _AD_INSTALLEDMODULES;
- Read upRead up
- Exclude checks
CamelCaseVariableName
Since: 0.2
It is considered best practice to use the camelCase notation to name variables.
Example
class ClassName {
public function doSomething() {
$data_module = new DataModule();
}
}
Source
The variable $protector_is_active is not named in camelCase. Open
function b_system_admin_warnings_show() {
$block = array();
$block['msg'] = array();
// Check if PDO is being used - if not, issue a warning, because it is being removed from PHP
- Read upRead up
- Exclude checks
CamelCaseVariableName
Since: 0.2
It is considered best practice to use the camelCase notation to name variables.
Example
class ClassName {
public function doSomething() {
$data_module = new DataModule();
}
}
Source
The variable $module_handler is not named in camelCase. Open
function b_system_admin_modules_show() {
$block['mods'] = array();
$module_handler = icms::handler('icms_module');
$moduleperm_handler = icms::handler('icms_member_groupperm');
$criteria = new icms_db_criteria_Compo();
- Read upRead up
- Exclude checks
CamelCaseVariableName
Since: 0.2
It is considered best practice to use the camelCase notation to name variables.
Example
class ClassName {
public function doSomething() {
$data_module = new DataModule();
}
}
Source
The variable $admin_perm is not named in camelCase. Open
function b_system_admin_modules_show() {
$block['mods'] = array();
$module_handler = icms::handler('icms_module');
$moduleperm_handler = icms::handler('icms_member_groupperm');
$criteria = new icms_db_criteria_Compo();
- Read upRead up
- Exclude checks
CamelCaseVariableName
Since: 0.2
It is considered best practice to use the camelCase notation to name variables.
Example
class ClassName {
public function doSomething() {
$data_module = new DataModule();
}
}
Source
The variable $sysperm_handler is not named in camelCase. Open
function b_system_admin_cp_new_show() {
global $icmsTpl, $icmsConfig;
$block['lang_cp'] = _CPHOME;
- Read upRead up
- Exclude checks
CamelCaseVariableName
Since: 0.2
It is considered best practice to use the camelCase notation to name variables.
Example
class ClassName {
public function doSomething() {
$data_module = new DataModule();
}
}
Source
The variable $mod_version_file is not named in camelCase. Open
function b_system_admin_cp_show() {
global $icmsTpl, $icmsConfig;
$block['lang_cp'] = _CPHOME;
$block['lang_insmodules'] = _AD_INSTALLEDMODULES;
- Read upRead up
- Exclude checks
CamelCaseVariableName
Since: 0.2
It is considered best practice to use the camelCase notation to name variables.
Example
class ClassName {
public function doSomething() {
$data_module = new DataModule();
}
}
Source
The variable $protector_is_active is not named in camelCase. Open
function b_system_admin_warnings_show() {
$block = array();
$block['msg'] = array();
// Check if PDO is being used - if not, issue a warning, because it is being removed from PHP
- Read upRead up
- Exclude checks
CamelCaseVariableName
Since: 0.2
It is considered best practice to use the camelCase notation to name variables.
Example
class ClassName {
public function doSomething() {
$data_module = new DataModule();
}
}
Source
The variable $config_handler is not named in camelCase. Open
function b_system_admin_warnings_show() {
$block = array();
$block['msg'] = array();
// Check if PDO is being used - if not, issue a warning, because it is being removed from PHP
- Read upRead up
- Exclude checks
CamelCaseVariableName
Since: 0.2
It is considered best practice to use the camelCase notation to name variables.
Example
class ClassName {
public function doSomething() {
$data_module = new DataModule();
}
}
Source
The variable $mod_version_file is not named in camelCase. Open
function b_system_admin_cp_show() {
global $icmsTpl, $icmsConfig;
$block['lang_cp'] = _CPHOME;
$block['lang_insmodules'] = _AD_INSTALLEDMODULES;
- Read upRead up
- Exclude checks
CamelCaseVariableName
Since: 0.2
It is considered best practice to use the camelCase notation to name variables.
Example
class ClassName {
public function doSomething() {
$data_module = new DataModule();
}
}
Source
The variable $admin_dir is not named in camelCase. Open
function b_system_admin_cp_new_show() {
global $icmsTpl, $icmsConfig;
$block['lang_cp'] = _CPHOME;
- Read upRead up
- Exclude checks
CamelCaseVariableName
Since: 0.2
It is considered best practice to use the camelCase notation to name variables.
Example
class ClassName {
public function doSomething() {
$data_module = new DataModule();
}
}
Source
The variable $mod_version_file is not named in camelCase. Open
function b_system_admin_cp_new_show() {
global $icmsTpl, $icmsConfig;
$block['lang_cp'] = _CPHOME;
- Read upRead up
- Exclude checks
CamelCaseVariableName
Since: 0.2
It is considered best practice to use the camelCase notation to name variables.
Example
class ClassName {
public function doSomething() {
$data_module = new DataModule();
}
}
Source
The variable $mod_version_file is not named in camelCase. Open
function b_system_admin_cp_new_show() {
global $icmsTpl, $icmsConfig;
$block['lang_cp'] = _CPHOME;
- Read upRead up
- Exclude checks
CamelCaseVariableName
Since: 0.2
It is considered best practice to use the camelCase notation to name variables.
Example
class ClassName {
public function doSomething() {
$data_module = new DataModule();
}
}
Source
The variable $all_ok is not named in camelCase. Open
function b_system_admin_cp_new_show() {
global $icmsTpl, $icmsConfig;
$block['lang_cp'] = _CPHOME;
- Read upRead up
- Exclude checks
CamelCaseVariableName
Since: 0.2
It is considered best practice to use the camelCase notation to name variables.
Example
class ClassName {
public function doSomething() {
$data_module = new DataModule();
}
}
Source
The variable $all_ok is not named in camelCase. Open
function b_system_admin_cp_show() {
global $icmsTpl, $icmsConfig;
$block['lang_cp'] = _CPHOME;
$block['lang_insmodules'] = _AD_INSTALLEDMODULES;
- Read upRead up
- Exclude checks
CamelCaseVariableName
Since: 0.2
It is considered best practice to use the camelCase notation to name variables.
Example
class ClassName {
public function doSomething() {
$data_module = new DataModule();
}
}
Source
The variable $sysperm_handler is not named in camelCase. Open
function b_system_admin_cp_show() {
global $icmsTpl, $icmsConfig;
$block['lang_cp'] = _CPHOME;
$block['lang_insmodules'] = _AD_INSTALLEDMODULES;
- Read upRead up
- Exclude checks
CamelCaseVariableName
Since: 0.2
It is considered best practice to use the camelCase notation to name variables.
Example
class ClassName {
public function doSomething() {
$data_module = new DataModule();
}
}
Source
The variable $all_ok is not named in camelCase. Open
function b_system_admin_cp_show() {
global $icmsTpl, $icmsConfig;
$block['lang_cp'] = _CPHOME;
$block['lang_insmodules'] = _AD_INSTALLEDMODULES;
- Read upRead up
- Exclude checks
CamelCaseVariableName
Since: 0.2
It is considered best practice to use the camelCase notation to name variables.
Example
class ClassName {
public function doSomething() {
$data_module = new DataModule();
}
}
Source
The variable $admin_dir is not named in camelCase. Open
function b_system_admin_cp_new_show() {
global $icmsTpl, $icmsConfig;
$block['lang_cp'] = _CPHOME;
- Read upRead up
- Exclude checks
CamelCaseVariableName
Since: 0.2
It is considered best practice to use the camelCase notation to name variables.
Example
class ClassName {
public function doSomething() {
$data_module = new DataModule();
}
}