AppStateESS/InternshipInventory

View on GitHub
class/SubselectPager.php

Summary

Maintainability
F
1 wk
Test Coverage

initialize accesses the super-global variable $_SESSION.
Open

    public function initialize($load_rows=true)
    {
        $order_set = false;
        $this->table_columns = $this->db->getTableColumns();

Severity: Minor
Found in class/SubselectPager.php by phpmd

Superglobals

Since: 0.2

Accessing a super-global variable directly is considered a bad practice. These variables should be encapsulated in objects that are provided by a framework, for instance.

Example

class Foo {
    public function bar() {
        $name = $_POST['foo'];
    }
}

Source

initialize accesses the super-global variable $_SESSION.
Open

    public function initialize($load_rows=true)
    {
        $order_set = false;
        $this->table_columns = $this->db->getTableColumns();

Severity: Minor
Found in class/SubselectPager.php by phpmd

Superglobals

Since: 0.2

Accessing a super-global variable directly is considered a bad practice. These variables should be encapsulated in objects that are provided by a framework, for instance.

Example

class Foo {
    public function bar() {
        $name = $_POST['foo'];
    }
}

Source

saveLastView accesses the super-global variable $_SESSION.
Open

    public function saveLastView()
    {
        $_SESSION['DBPager_Last_View'][$this->table] = PHPWS_Core::getCurrentUrl();
    }
Severity: Minor
Found in class/SubselectPager.php by phpmd

Superglobals

Since: 0.2

Accessing a super-global variable directly is considered a bad practice. These variables should be encapsulated in objects that are provided by a framework, for instance.

Example

class Foo {
    public function bar() {
        $name = $_POST['foo'];
    }
}

Source

clearQuery accesses the super-global variable $_SESSION.
Open

    public function clearQuery()
    {
        if (isset($_SESSION['DB_Cache'])) {
            unset($_SESSION['DB_Cache'][$this->module][$this->template]);
        }
Severity: Minor
Found in class/SubselectPager.php by phpmd

Superglobals

Since: 0.2

Accessing a super-global variable directly is considered a bad practice. These variables should be encapsulated in objects that are provided by a framework, for instance.

Example

class Foo {
    public function bar() {
        $name = $_POST['foo'];
    }
}

Source

clearQuery accesses the super-global variable $_SESSION.
Open

    public function clearQuery()
    {
        if (isset($_SESSION['DB_Cache'])) {
            unset($_SESSION['DB_Cache'][$this->module][$this->template]);
        }
Severity: Minor
Found in class/SubselectPager.php by phpmd

Superglobals

Since: 0.2

Accessing a super-global variable directly is considered a bad practice. These variables should be encapsulated in objects that are provided by a framework, for instance.

Example

class Foo {
    public function bar() {
        $name = $_POST['foo'];
    }
}

Source

getLinkValues accesses the super-global variable $GLOBALS.
Open

    public function getLinkValues()
    {
        $output = null;
        if (isset($GLOBALS['DBPager_Link_Values'])) {
            return $GLOBALS['DBPager_Link_Values'];
Severity: Minor
Found in class/SubselectPager.php by phpmd

Superglobals

Since: 0.2

Accessing a super-global variable directly is considered a bad practice. These variables should be encapsulated in objects that are provided by a framework, for instance.

Example

class Foo {
    public function bar() {
        $name = $_POST['foo'];
    }
}

Source

initialize accesses the super-global variable $_SESSION.
Open

    public function initialize($load_rows=true)
    {
        $order_set = false;
        $this->table_columns = $this->db->getTableColumns();

Severity: Minor
Found in class/SubselectPager.php by phpmd

Superglobals

Since: 0.2

Accessing a super-global variable directly is considered a bad practice. These variables should be encapsulated in objects that are provided by a framework, for instance.

Example

class Foo {
    public function bar() {
        $name = $_POST['foo'];
    }
}

Source

getLinkValues accesses the super-global variable $GLOBALS.
Open

    public function getLinkValues()
    {
        $output = null;
        if (isset($GLOBALS['DBPager_Link_Values'])) {
            return $GLOBALS['DBPager_Link_Values'];
Severity: Minor
Found in class/SubselectPager.php by phpmd

Superglobals

Since: 0.2

Accessing a super-global variable directly is considered a bad practice. These variables should be encapsulated in objects that are provided by a framework, for instance.

Example

class Foo {
    public function bar() {
        $name = $_POST['foo'];
    }
}

Source

getLastView accesses the super-global variable $_SESSION.
Open

    public static function getLastView($table)
    {
        if (isset($_SESSION['DBPager_Last_View'][$table])) {
            return $_SESSION['DBPager_Last_View'][$table];
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

Superglobals

Since: 0.2

Accessing a super-global variable directly is considered a bad practice. These variables should be encapsulated in objects that are provided by a framework, for instance.

Example

class Foo {
    public function bar() {
        $name = $_POST['foo'];
    }
}

Source

getLinkValues accesses the super-global variable $GLOBALS.
Open

    public function getLinkValues()
    {
        $output = null;
        if (isset($GLOBALS['DBPager_Link_Values'])) {
            return $GLOBALS['DBPager_Link_Values'];
Severity: Minor
Found in class/SubselectPager.php by phpmd

Superglobals

Since: 0.2

Accessing a super-global variable directly is considered a bad practice. These variables should be encapsulated in objects that are provided by a framework, for instance.

Example

class Foo {
    public function bar() {
        $name = $_POST['foo'];
    }
}

Source

getLastView accesses the super-global variable $_SESSION.
Open

    public static function getLastView($table)
    {
        if (isset($_SESSION['DBPager_Last_View'][$table])) {
            return $_SESSION['DBPager_Last_View'][$table];
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

Superglobals

Since: 0.2

Accessing a super-global variable directly is considered a bad practice. These variables should be encapsulated in objects that are provided by a framework, for instance.

Example

class Foo {
    public function bar() {
        $name = $_POST['foo'];
    }
}

Source

File SubselectPager.php has 982 lines of code (exceeds 250 allowed). Consider refactoring.
Open

<?php
/**
 * This file is part of Internship Inventory.
 *
 * Internship Inventory is free software: you can redistribute it and/or modify
Severity: Major
Found in class/SubselectPager.php - About 2 days to fix

Function getPageLinks has a Cognitive Complexity of 63 (exceeds 5 allowed). Consider refactoring.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php - About 1 day to fix

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 getPageRows has a Cognitive Complexity of 59 (exceeds 5 allowed). Consider refactoring.
Open

    public function getPageRows()
    {
        $template = null;
        $count = 0;

Severity: Minor
Found in class/SubselectPager.php - About 1 day to fix

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

SubselectPager has 55 functions (exceeds 20 allowed). Consider refactoring.
Open

class SubselectPager extends \DBPager {

    public function __construct($table, $class=null)
    {
        parent::__construct($table, $class);
Severity: Major
Found in class/SubselectPager.php - About 7 hrs to fix

Function initialize has a Cognitive Complexity of 44 (exceeds 5 allowed). Consider refactoring.
Open

    public function initialize($load_rows=true)
    {
        $order_set = false;
        $this->table_columns = $this->db->getTableColumns();

Severity: Minor
Found in class/SubselectPager.php - About 6 hrs to fix

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 get has a Cognitive Complexity of 34 (exceeds 5 allowed). Consider refactoring.
Open

    public function get($return_blank_results=true)
    {
        $template = array();

        if (empty($this->display_rows)) {
Severity: Minor
Found in class/SubselectPager.php - About 5 hrs to fix

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 getPageLinks has 112 lines of code (exceeds 25 allowed). Consider refactoring.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Major
Found in class/SubselectPager.php - About 4 hrs to fix

Method initialize has 110 lines of code (exceeds 25 allowed). Consider refactoring.
Open

    public function initialize($load_rows=true)
    {
        $order_set = false;
        $this->table_columns = $this->db->getTableColumns();

Severity: Major
Found in class/SubselectPager.php - About 4 hrs to fix

Function getSortButtons has a Cognitive Complexity of 26 (exceeds 5 allowed). Consider refactoring.
Open

    public function getSortButtons(&$template)
    {
        if (empty($this->table_columns)) {
            return null;
        }
Severity: Minor
Found in class/SubselectPager.php - About 3 hrs to fix

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

The class SubselectPager has 22 public methods. Consider refactoring SubselectPager to keep number of public methods under 10.
Open

class SubselectPager extends \DBPager {

    public function __construct($table, $class=null)
    {
        parent::__construct($table, $class);
Severity: Minor
Found in class/SubselectPager.php by phpmd

TooManyPublicMethods

Since: 0.1

A class with too many public methods is probably a good suspect for refactoring, in order to reduce its complexity and find a way to have more fine grained objects.

By default it ignores methods starting with 'get' or 'set'.

Example

Source https://phpmd.org/rules/codesize.html#toomanypublicmethods

The class SubselectPager has an overall complexity of 250 which is very high. The configured complexity threshold is 50.
Open

class SubselectPager extends \DBPager {

    public function __construct($table, $class=null)
    {
        parent::__construct($table, $class);
Severity: Minor
Found in class/SubselectPager.php by phpmd

Method getSortButtons has 63 lines of code (exceeds 25 allowed). Consider refactoring.
Open

    public function getSortButtons(&$template)
    {
        if (empty($this->table_columns)) {
            return null;
        }
Severity: Major
Found in class/SubselectPager.php - About 2 hrs to fix

Function createReport has a Cognitive Complexity of 18 (exceeds 5 allowed). Consider refactoring.
Open

    function createReport()
    {
        if ($this->class) {
            $methods = get_class_methods($this->class);
            if (in_array($this->report_row, $methods)) {
Severity: Minor
Found in class/SubselectPager.php - About 2 hrs to fix

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 get has 59 lines of code (exceeds 25 allowed). Consider refactoring.
Open

    public function get($return_blank_results=true)
    {
        $template = array();

        if (empty($this->display_rows)) {
Severity: Major
Found in class/SubselectPager.php - About 2 hrs to fix

Method getPageRows has 59 lines of code (exceeds 25 allowed). Consider refactoring.
Open

    public function getPageRows()
    {
        $template = null;
        $count = 0;

Severity: Major
Found in class/SubselectPager.php - About 2 hrs to fix

Function getLinkValues has a Cognitive Complexity of 17 (exceeds 5 allowed). Consider refactoring.
Open

    public function getLinkValues()
    {
        $output = null;
        if (isset($GLOBALS['DBPager_Link_Values'])) {
            return $GLOBALS['DBPager_Link_Values'];
Severity: Minor
Found in class/SubselectPager.php - About 2 hrs to fix

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 getLinkValues has 53 lines of code (exceeds 25 allowed). Consider refactoring.
Open

    public function getLinkValues()
    {
        $output = null;
        if (isset($GLOBALS['DBPager_Link_Values'])) {
            return $GLOBALS['DBPager_Link_Values'];
Severity: Major
Found in class/SubselectPager.php - About 2 hrs to fix

Method createReport has 47 lines of code (exceeds 25 allowed). Consider refactoring.
Open

    function createReport()
    {
        if ($this->class) {
            $methods = get_class_methods($this->class);
            if (in_array($this->report_row, $methods)) {
Severity: Minor
Found in class/SubselectPager.php - About 1 hr to fix

Function getTotalRows has a Cognitive Complexity of 12 (exceeds 5 allowed). Consider refactoring.
Open

    public function getTotalRows()
    {
        /**
         * if total_column is set, use it to get total rows
         */
Severity: Minor
Found in class/SubselectPager.php - About 1 hr to fix

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 addToggleFunction has a Cognitive Complexity of 12 (exceeds 5 allowed). Consider refactoring.
Open

    public function addToggleFunction($function, $toggle=2)
    {
        if (empty($function) || $toggle < 2) {
            return false;
        }
Severity: Minor
Found in class/SubselectPager.php - About 1 hr to fix

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 joinResult has 35 lines of code (exceeds 25 allowed). Consider refactoring.
Open

    public function joinResult($source_column, $join_table, $join_column, $content_column, $new_name=null, $searchable=false)
    {
        // TODO: this will break if you have more than one db pager at a time
        // TODO: make this a private member variable
        static $join_match = null;
Severity: Minor
Found in class/SubselectPager.php - About 1 hr to fix

Method getSearchBox has 31 lines of code (exceeds 25 allowed). Consider refactoring.
Open

    public function getSearchBox()
    {
        static $id_count = 0;

        if ($id_count) {
Severity: Minor
Found in class/SubselectPager.php - About 1 hr to fix

The class SubselectPager has 55 public methods and attributes. Consider reducing the number of public items to less than 45.
Open

class SubselectPager extends \DBPager {

    public function __construct($table, $class=null)
    {
        parent::__construct($table, $class);
Severity: Minor
Found in class/SubselectPager.php by phpmd

ExcessivePublicCount

Since: 0.1

A large number of public methods and attributes declared in a class can indicate the class may need to be broken up as increased effort will be required to thoroughly test it.

Example

public class Foo {
    public $value;
    public $something;
    public $var;
    // [... more more public attributes ...]

    public function doWork() {}
    public function doMoreWork() {}
    public function doWorkAgain() {}
    // [... more more public methods ...]
}

Source https://phpmd.org/rules/codesize.html#excessivepubliccount

Function addRowFunction has a Cognitive Complexity of 10 (exceeds 5 allowed). Consider refactoring.
Open

    public function addRowFunction($function)
    {
        if (is_string($function) && function_exists($function)) {
            $this->run_function = $function;
            return true;
Severity: Minor
Found in class/SubselectPager.php - About 1 hr to fix

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 getTotalRows has 26 lines of code (exceeds 25 allowed). Consider refactoring.
Open

    public function getTotalRows()
    {
        /**
         * if total_column is set, use it to get total rows
         */
Severity: Minor
Found in class/SubselectPager.php - About 1 hr to fix

Function setSearch has a Cognitive Complexity of 9 (exceeds 5 allowed). Consider refactoring.
Open

    public function setSearch()
    {
        $args = func_get_args();

        if (sizeof($args) == 1 && is_array($args[0])) {
Severity: Minor
Found in class/SubselectPager.php - About 55 mins to fix

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 joinResult has 6 arguments (exceeds 4 allowed). Consider refactoring.
Open

    public function joinResult($source_column, $join_table, $join_column, $content_column, $new_name=null, $searchable=false)
Severity: Minor
Found in class/SubselectPager.php - About 45 mins to fix

Method addWhere has 5 arguments (exceeds 4 allowed). Consider refactoring.
Open

    public function addWhere($column, $value, $operator=null, $conj=null, $group=null)
Severity: Minor
Found in class/SubselectPager.php - About 35 mins to fix

Function joinResult has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring.
Open

    public function joinResult($source_column, $join_table, $join_column, $content_column, $new_name=null, $searchable=false)
    {
        // TODO: this will break if you have more than one db pager at a time
        // TODO: make this a private member variable
        static $join_match = null;
Severity: Minor
Found in class/SubselectPager.php - About 35 mins to fix

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 getLimitList has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring.
Open

    public function getLimitList()
    {
        $values = $this->getLinkValues();
        unset($values['limit']);

Severity: Minor
Found in class/SubselectPager.php - About 35 mins to fix

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

Avoid too many return statements within this method.
Open

            return null;
Severity: Major
Found in class/SubselectPager.php - About 30 mins to fix

Avoid too many return statements within this method.
Open

            return false;
Severity: Major
Found in class/SubselectPager.php - About 30 mins to fix

Avoid too many return statements within this method.
Open

        return PHPWS_Template::process($template, $this->module, $this->template);
Severity: Major
Found in class/SubselectPager.php - About 30 mins to fix

Function getSearchBox has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring.
Open

    public function getSearchBox()
    {
        static $id_count = 0;

        if ($id_count) {
Severity: Minor
Found in class/SubselectPager.php - About 25 mins to fix

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

The method getSortButtons() has an NPath complexity of 388. The configured NPath complexity threshold is 200.
Open

    public function getSortButtons(&$template)
    {
        if (empty($this->table_columns)) {
            return null;
        }
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 method getPageLinks() has 134 lines of code. Current threshold is set to 100. Avoid really long methods.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

The method getPageRows() has an NPath complexity of 6530. The configured NPath complexity threshold is 200.
Open

    public function getPageRows()
    {
        $template = null;
        $count = 0;

Severity: Minor
Found in class/SubselectPager.php by phpmd

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 method initialize() has 183 lines of code. Current threshold is set to 100. Avoid really long methods.
Open

    public function initialize($load_rows=true)
    {
        $order_set = false;
        $this->table_columns = $this->db->getTableColumns();

Severity: Minor
Found in class/SubselectPager.php by phpmd

The method get() has an NPath complexity of 1152. The configured NPath complexity threshold is 200.
Open

    public function get($return_blank_results=true)
    {
        $template = array();

        if (empty($this->display_rows)) {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 method getLinkValues() has an NPath complexity of 1728. The configured NPath complexity threshold is 200.
Open

    public function getLinkValues()
    {
        $output = null;
        if (isset($GLOBALS['DBPager_Link_Values'])) {
            return $GLOBALS['DBPager_Link_Values'];
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 class SubselectPager has 1334 lines of code. Current threshold is 1000. Avoid really long classes.
Open

class SubselectPager extends \DBPager {

    public function __construct($table, $class=null)
    {
        parent::__construct($table, $class);
Severity: Minor
Found in class/SubselectPager.php by phpmd

The method initialize() has an NPath complexity of 58060800. The configured NPath complexity threshold is 200.
Open

    public function initialize($load_rows=true)
    {
        $order_set = false;
        $this->table_columns = $this->db->getTableColumns();

Severity: Minor
Found in class/SubselectPager.php by phpmd

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 method getPageLinks() has an NPath complexity of 37600. The configured NPath complexity threshold is 200.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 method getPageLinks() has a Cyclomatic Complexity of 29. The configured cyclomatic complexity threshold is 10.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 method getLinkValues() has a Cyclomatic Complexity of 13. The configured cyclomatic complexity threshold is 10.
Open

    public function getLinkValues()
    {
        $output = null;
        if (isset($GLOBALS['DBPager_Link_Values'])) {
            return $GLOBALS['DBPager_Link_Values'];
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 method getPageRows() has a Cyclomatic Complexity of 25. The configured cyclomatic complexity threshold is 10.
Open

    public function getPageRows()
    {
        $template = null;
        $count = 0;

Severity: Minor
Found in class/SubselectPager.php by phpmd

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 method get() has a Cyclomatic Complexity of 16. The configured cyclomatic complexity threshold is 10.
Open

    public function get($return_blank_results=true)
    {
        $template = array();

        if (empty($this->display_rows)) {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 method initialize() has a Cyclomatic Complexity of 35. The configured cyclomatic complexity threshold is 10.
Open

    public function initialize($load_rows=true)
    {
        $order_set = false;
        $this->table_columns = $this->db->getTableColumns();

Severity: Minor
Found in class/SubselectPager.php by phpmd

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 method getSortButtons() has a Cyclomatic Complexity of 12. The configured cyclomatic complexity threshold is 10.
Open

    public function getSortButtons(&$template)
    {
        if (empty($this->table_columns)) {
            return null;
        }
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 method createReport() has a Cyclomatic Complexity of 10. The configured cyclomatic complexity threshold is 10.
Open

    function createReport()
    {
        if ($this->class) {
            $methods = get_class_methods($this->class);
            if (in_array($this->report_row, $methods)) {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 '$cache' which will lead to PHP notices.
Open

            $cache['search'] = $this->search;
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 '$cache' which will lead to PHP notices.
Open

            $cache['limit'] = $this->limit;
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 '$orderby_dir' which will lead to PHP notices.
Open

            $this->orderby_dir = $orderby_dir;
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 '$cache' which will lead to PHP notices.
Open

            $cache['orderby'] = $this->orderby;
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 '$cache' which will lead to PHP notices.
Open

            $_SESSION['DB_Cache'][$this->module][$this->cache_identifier] = $cache;
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 '$cache' which will lead to PHP notices.
Open

            $cache['orderby_dir'] = $this->orderby_dir;
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 '$limit' which will lead to PHP notices.
Open

            $this->limit = $limit;
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 '$current_page' which will lead to PHP notices.
Open

            $this->current_page = $current_page;
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 '$cache' which will lead to PHP notices.
Open

            $cache['current_page'] = $this->current_page;
Severity: Minor
Found in class/SubselectPager.php by phpmd

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

The method initialize has a boolean flag argument $load_rows, which is a certain sign of a Single Responsibility Principle violation.
Open

    public function initialize($load_rows=true)
Severity: Minor
Found in class/SubselectPager.php by phpmd

BooleanArgumentFlag

Since: 1.4.0

A boolean flag argument is a reliable indicator for a violation of the Single Responsibility Principle (SRP). You can fix this problem by extracting the logic in the boolean flag into its own class or method.

Example

class Foo {
    public function bar($flag = true) {
    }
}

Source https://phpmd.org/rules/cleancode.html#booleanargumentflag

The method setOrder has a boolean flag argument $only_if_empty, which is a certain sign of a Single Responsibility Principle violation.
Open

    public function setOrder($column, $direction='asc', $only_if_empty=false)
Severity: Minor
Found in class/SubselectPager.php by phpmd

BooleanArgumentFlag

Since: 1.4.0

A boolean flag argument is a reliable indicator for a violation of the Single Responsibility Principle (SRP). You can fix this problem by extracting the logic in the boolean flag into its own class or method.

Example

class Foo {
    public function bar($flag = true) {
    }
}

Source https://phpmd.org/rules/cleancode.html#booleanargumentflag

Missing class import via use statement (line '60', column '27').
Open

                throw new \Exception ($result->toString());
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 '223', column '23').
Open

            throw new \Exception($count->toString());
Severity: Minor
Found in class/SubselectPager.php by phpmd

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

The method joinResult has a boolean flag argument $searchable, which is a certain sign of a Single Responsibility Principle violation.
Open

    public function joinResult($source_column, $join_table, $join_column, $content_column, $new_name=null, $searchable=false)
Severity: Minor
Found in class/SubselectPager.php by phpmd

BooleanArgumentFlag

Since: 1.4.0

A boolean flag argument is a reliable indicator for a violation of the Single Responsibility Principle (SRP). You can fix this problem by extracting the logic in the boolean flag into its own class or method.

Example

class Foo {
    public function bar($flag = true) {
    }
}

Source https://phpmd.org/rules/cleancode.html#booleanargumentflag

The method cacheQueries has a boolean flag argument $cache, which is a certain sign of a Single Responsibility Principle violation.
Open

    public function cacheQueries($cache=true)
Severity: Minor
Found in class/SubselectPager.php by phpmd

BooleanArgumentFlag

Since: 1.4.0

A boolean flag argument is a reliable indicator for a violation of the Single Responsibility Principle (SRP). You can fix this problem by extracting the logic in the boolean flag into its own class or method.

Example

class Foo {
    public function bar($flag = true) {
    }
}

Source https://phpmd.org/rules/cleancode.html#booleanargumentflag

Missing class import via use statement (line '1226', column '21').
Open

        $form = new \PHPWS_Form($id);
Severity: Minor
Found in class/SubselectPager.php by phpmd

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

The method get has a boolean flag argument $return_blank_results, which is a certain sign of a Single Responsibility Principle violation.
Open

    public function get($return_blank_results=true)
Severity: Minor
Found in class/SubselectPager.php by phpmd

BooleanArgumentFlag

Since: 1.4.0

A boolean flag argument is a reliable indicator for a violation of the Single Responsibility Principle (SRP). You can fix this problem by extracting the logic in the boolean flag into its own class or method.

Example

class Foo {
    public function bar($flag = true) {
    }
}

Source https://phpmd.org/rules/cleancode.html#booleanargumentflag

Missing class import via use statement (line '82', column '23').
Open

            throw new \Exception($rows);
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 '1305', column '19').
Open

        $dl = new \HTTP_Download;
Severity: Minor
Found in class/SubselectPager.php by phpmd

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

The method setTotalColumn uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
Open

        } else {
            $this->total_column = trim($column);
        }
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 '\PHPWS_Text' in method 'getPageLinks'.
Open

            $pageList[] = \PHPWS_Text::moduleLink('&gt;', $module, $values, null, _('Forward one page'));
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 getLimitList uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
Open

        } else {
            $module = & $this->module;
        }
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 getLastView uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
Open

        } else {
            return null;
        }
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 joinResult uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
Open

        } else {
            $tbl_idx = $index;
        }
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 setSearch uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
Open

            } else {
                $preg = '/[^\.\w]/u';
            }
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 '\PHPWS_Text' in method 'getPageLinks'.
Open

                $pageList[] = \PHPWS_Text::moduleLink('&lt;&lt;&lt;', $module, $values, null, _('Back 50 pages'));
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 '\PHPWS_Text' in method 'getPageLinks'.
Open

                    $pageList[] = \PHPWS_Text::moduleLink($i, $module, $values, null, sprintf(_('Go to page %s'), $i));
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 getSortButtons uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
Open

            } else {
                $module = & $this->module;
            }
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 get uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
Open

                } else {
                    $rowitem['TOGGLE'] = null;
                }
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 addToggleFunction uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
Open

            } else {
                $method = & $function[1];
            }
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 addToggleFunction uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
Open

        } else {
            return false;
        }
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 addRowFunction uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
Open

        } else {
            return false;
        }
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 '\PHPWS_Text' in method 'getPageLinks'.
Open

                            $pageList[] = \PHPWS_Text::moduleLink($i, $module, $values, null, sprintf(_('Go to page %s'), $i));
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 get uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
Open

                    } else {
                        $rowitem['TOGGLE'] = $this->toggles[$count];
                        $count++;

                        if ($count >= $max_tog) {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 getPageLinks uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
Open

                    } else {
                        $divider += $remaining_pages;
                        $front_skip = floor($beginning_pages / $divider);
                        $back_skip = 1;
                    }
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 get uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
Open

        } else {
            $template['EMPTY_MESSAGE'] = $this->empty_message;
        }
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 loadSearch uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
Open

        } else {
            $preg = '/[^\w\s]/u';
        }
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 createReport uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
Open

            } else {
                $func_type = 'none';
            }
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 '\PHPWS_Core' in method 'createReport'.
Open

                    $result = PHPWS_Core::stripObjValues($foo);
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 getPageLinks uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
Open

                } else {
                    $values['pg'] = $i;
                    $pageList[] = \PHPWS_Text::moduleLink($i, $module, $values, null, sprintf(_('Go to page %s'), $i));
                }
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 getPageLinks uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
Open

        } else {
            $pageList[] = "[$current_page]";
        }
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 getSortButtons uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
Open

                } else {
                    $alt .= _('Unsorted');
                    $button = Icon::get('sort');
                    $values['orderby_dir'] = 'asc';
                }
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 getSortButtons uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
Open

            } else {
                $alt .= _('Unsorted');
                $button = Icon::get('sort');
                $button->setStyle('margin-right : 5px');
                $button->setAlt($alt);
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 '\PHPWS_Text' in method 'getSortButtons'.
Open

            $link = \PHPWS_Text::moduleLink($button_string, $module, $values, null, $alt);
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 getTotalRows uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
Open

            } else {
                return $this->fullRowCount();
            }
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 '\PHPWS_Error' in method 'getSearchBox'.
Open

        if (PHPWS_Error::isError($template)) {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 getPageLinks uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
Open

        } else {
            $current_page = $this->current_page;
            $total_pages = $this->total_pages;
        }
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 getPageLinks uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
Open

                } else {
                    $front_skip = round($beginning_pages / $divider);
                    $back_skip = round($remaining_pages / $divider);
                }
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 '\PHPWS_Text' in method 'createReport'.
Open

        $tmp_file = \PHPWS_Text::randomString(10) . time();
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 getSortButtons uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
Open

                } else {
                    $alt = strip_tags($this->sort_headers[$varname]['title']) . ' - ';
                }
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 '\Icon' in method 'getSortButtons'.
Open

                $button = Icon::get('sort');
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 createReport uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
Open

            } else {
                if (is_object($foo)) {
                    $result = PHPWS_Core::stripObjValues($foo);
                } else {
                    $result = & $foo;
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 setSearch uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
Open

        } else {
            $col_list = $args;
        }
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 addRowFunction uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
Open

            } else {
                return false;
            }
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 getSearchBox uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
Open

        } else {
            $id = 'search_list';
            $id_count++;
        }
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 getPageLinks uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
Open

            } else {
                $beginning_pages = $current_page - 1;
                $remaining_pages = $total_pages - $current_page;

                if ($remaining_pages < $divider) {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 getLinkValues uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
Open

        } else {
            $preg = '/[^\w\s]/u';
        }
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 '\PHPWS_Text' in method 'getReportLink'.
Open

            $part = \PHPWS_Text::moduleLink(_('Partial'), $module, $values, null, _('Download a partial CSV file'));
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 '\PHPWS_Template' in method 'get'.
Open

        return PHPWS_Template::process($template, $this->module, $this->template);
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 initialize uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
Open

            } else {
                $full_report = false;
            }
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 initialize uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
Open

            } else {
                $col_name = $this->orderby;
            }
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 '\PHPWS_Text' in method 'getPageLinks'.
Open

                        $pageList[] = \PHPWS_Text::moduleLink($j, $module, $values, null, sprintf(_('Go to page %s'), $j));
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 getPageLinks uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
Open

        } else {
            for ($i = 2; $i < $total_pages; $i++) {
                if ($i == $current_page) {
                    $pageList[] = "[$i]";
                } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 '\Icon' in method 'getSortButtons'.
Open

                    $button = Icon::get('sort-up');
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 '\PHPWS_Text' in method 'getReportLink'.
Open

            $all = \PHPWS_Text::moduleLink(_('All'), $module, $values, null, _('Download a complete CSV file'));
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 getReportLink uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
Open

        } else {
            $values['dbprt'] = 'csva';
            return \PHPWS_Text::moduleLink(_('CSV Report'), $module, $values, null, _('Download a complete CSV file'));
        }
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 '\PHPWS_Text' in method 'getReportLink'.
Open

            return \PHPWS_Text::moduleLink(_('CSV Report'), $module, $values, null, _('Download a complete CSV file'));
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 getLimitList uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
Open

            } else {
                $values['limit'] = & $limit;
                $links[] = \PHPWS_Text::moduleLink($limit, $module, $values, null, sprintf(_('Limit results to %s rows'), $limit));
            }
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 getPageRows uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
Open

                    } else {
                        $row_result = call_user_func_array(array($disp_row, $this->row_tags['method']), $this->row_tags['variable']);
                    }
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 '\PHPWS_Error' in method 'get'.
Open

            return PHPWS_Error::get(DBPAGER_MODULE_NOT_SET, 'core', 'DBPager::get');
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 '266', column '17').
Open

    public function initialize($load_rows=true)
    {
        $order_set = false;
        $this->table_columns = $this->db->getTableColumns();

Severity: Minor
Found in class/SubselectPager.php by phpmd

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

The method initialize uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
Open

            } else {
                $orderby = $this->orderby;
            }
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 addToggleFunction uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
Open

            } else {
                return false;
            }
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 addRowFunction uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
Open

            } else {
                $method = & $function[1];
            }
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 '\PHPWS_Text' in method 'getPageLinks'.
Open

            $pageList[] = \PHPWS_Text::moduleLink('&lt;', $module, $values, null, _('Back one page'));
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 '\PHPWS_Text' in method 'getLimitList'.
Open

                $links[] = \PHPWS_Text::moduleLink($limit, $module, $values, null, sprintf(_('Limit results to %s rows'), $limit));
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 getPageLinks uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
Open

        } else {
            $pageList[] = '[1]';
        }
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 getPageLinks uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
Open

                        } else {
                            $pageList[] = "[$current_page]";
                        }
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 '\PHPWS_Text' in method 'getPageLinks'.
Open

                    $pageList[] = \PHPWS_Text::moduleLink($j, $module, $values, null, sprintf(_('Go to page %s'), $j));
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 initialize uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
Open

        } else {
            $search = null;
        }
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 '\PHPWS_Error' in method 'get'.
Open

            if (PHPWS_Error::isError($result)) {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 getPageRows uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
Open

            } else {
                foreach ($disp_row as $key => $value) {
                    $template[$count][strtoupper($key)] = $value;
                }

Severity: Minor
Found in class/SubselectPager.php by phpmd

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 '\PHPWS_Error' in method 'initialize'.
Open

        if (PHPWS_Error::isError($result)) {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 getAnchor uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
Open

        } else {
            return '#' . $this->anchor;
        }
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 '\PHPWS_Text' in method 'getPageLinks'.
Open

            $pageList[] = \PHPWS_Text::moduleLink($total_pages, $module, $values, null, _('Last page'));
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 getSortButtons uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
Open

            } else {
                $alt = '';
            }
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 getLinkValues uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
Open

            } else {
                $diff = $extra;
            }
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 createReport uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
Open

                } else {
                    $result = & $foo;
                }
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 '\PHPWS_Core' in method 'saveLastView'.
Open

        $_SESSION['DBPager_Last_View'][$this->table] = PHPWS_Core::getCurrentUrl();
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 '\PHPWS_Error' in method 'initialize'.
Open

        if (PHPWS_Error::isError($count)) {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 initialize uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
Open

            } else {
                $this->limit = DBPAGER_DEFAULT_LIMIT;
            }
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 '\PHPWS_Text' in method 'getPageLinks'.
Open

                    $pageList[] = \PHPWS_Text::moduleLink($j, $module, $values, null, sprintf(_('Go to page %s'), $j));
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 '\PHPWS_Error' in method 'get'.
Open

        if (PHPWS_Error::isError($rows)) {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 get uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
Open

                        } else {
                            $rowitem['TOGGLE'] = null;
                        }
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 initialize uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
Open

        } else {
            $result = $this->db->getObjects($this->class);
        }
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 getTotalRows uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
Open

        } else {
            /**
             * If total_column is not set check number of tables
             */
            if (count($this->db->tables) > 1) {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 '\PHPWS_Core' in method 'loadLink'.
Open

        $this->link = \PHPWS_Core::getCurrentUrl(true, false);
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 addRowTags uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
Open

        } else {
            $variables = null;
        }
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 '\PHPWS_Text' in method 'getPageLinks'.
Open

                $pageList[] = \PHPWS_Text::moduleLink('&gt;&gt;&gt;', $module, $values, null, _('Forward 50 pages'));
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 '\PHPWS_Error' in method 'get'.
Open

            return PHPWS_Error::get(DBPAGER_TEMPLATE_NOT_SET, 'core', 'DBPager::get');
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 '358', column '25').
Open

    public function getTotalRows()
    {
        /**
         * if total_column is set, use it to get total rows
         */
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 '\PHPWS_Text' in method 'getPageLinks'.
Open

            $pageList[] = \PHPWS_Text::moduleLink('1', $module, $values, null, _('First page'));
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 '\PHPWS_Text' in method 'getLinkValues'.
Open

        $extra = \PHPWS_Text::getGetValues();
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 '\PHPWS_Error' in method 'getSearchBox'.
Open

            PHPWS_Error::log($template);
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 '\DBPager' in method 'get'.
Open

        DBPager::plugPageTags($template);
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 initialize uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
Open

        } else {
            // No report requested
            $report = false;
            $full_report = false;
        }
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 initialize uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
Open

            }else{
                $this->table_columns = $this->needed_columns;
            }
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 initialize uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
Open

        } else {
            $this->clearQuery();
        }
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 '\PHPWS_Text' in method 'getPageLinks'.
Open

                $pageList[] = \PHPWS_Text::moduleLink('&lt;&lt;', $module, $values, null, _('Back 10 pages'));
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 '\Icon' in method 'getSortButtons'.
Open

                    $button = Icon::get('sort-down');
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 '\PHPWS_Text' in method 'getPageLinks'.
Open

                $pageList[] = \PHPWS_Text::moduleLink('&gt;&gt;', $module, $values, null, _('Forward 10 pages'));
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 getSortButtons uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
Open

        } else {
            $sort_columns = array_keys($this->sort_headers);
        }
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 '\Icon' in method 'getSortButtons'.
Open

                    $button = Icon::get('sort');
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 '\PHPWS_Error' in method 'getPageRows'.
Open

                        return PHPWS_Error::get(DBPAGER_NO_METHOD, 'core', 'DBPager::getPageRows', $this->class . ':' . $this->row_tags['method']);
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 unused local variables such as '$current_page'.
Open

            $this->current_page = $current_page;
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 '$row'.
Open

                $row = fputcsv($fp, $index_keys);
Severity: Minor
Found in class/SubselectPager.php by phpmd

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

The method createReport() contains an exit expression.
Open

        exit();
Severity: Minor
Found in class/SubselectPager.php by phpmd

ExitExpression

Since: 0.2

An exit-expression within regular code is untestable and therefore it should be avoided. Consider to move the exit-expression into some kind of startup script where an error/exception code is returned to the calling environment.

Example

class Foo {
    public function bar($param)  {
        if ($param === 42) {
            exit(23);
        }
    }
}

Source https://phpmd.org/rules/design.html#exitexpression

Avoid unused local variables such as '$limit'.
Open

            $this->limit = $limit;
Severity: Minor
Found in class/SubselectPager.php by phpmd

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

The method get() contains an exit expression.
Open

            exit();
Severity: Minor
Found in class/SubselectPager.php by phpmd

ExitExpression

Since: 0.2

An exit-expression within regular code is untestable and therefore it should be avoided. Consider to move the exit-expression into some kind of startup script where an error/exception code is returned to the calling environment.

Example

class Foo {
    public function bar($param)  {
        if ($param === 42) {
            exit(23);
        }
    }
}

Source https://phpmd.org/rules/design.html#exitexpression

Avoid unused local variables such as '$orderby_dir'.
Open

            $this->orderby_dir = $orderby_dir;
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 '$report'.
Open

            $report = true;
Severity: Minor
Found in class/SubselectPager.php by phpmd

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

TODO found
Open

        // TODO: make this a private member variable
Severity: Minor
Found in class/SubselectPager.php by fixme

TODO found
Open

    //TODO: Why is this recursive?
Severity: Minor
Found in class/SubselectPager.php by fixme

TODO found
Open

        // TODO: this will break if you have more than one db pager at a time
Severity: Minor
Found in class/SubselectPager.php by fixme

Call to method initCoreClass from undeclared class \PHPWS_Core
Open

\PHPWS_Core::initCoreClass('DBPager.php');
Severity: Critical
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->display_rows
Open

        if (empty($this->display_rows)) {
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->table_columns
Open

            if(isset($this->table_columns)){
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->orderby
Open

        if (empty($this->limit) && empty($this->orderby) &&
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->cache_identifier
Open

                empty($this->search) && isset($_SESSION['DB_Cache'][$this->module][$this->cache_identifier])) {
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->db
Open

            $this->db->addOrder($this->default_order . ' ' . $this->default_order_dir);
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->db
Open

        $this->row_query = $this->db->lastQuery();
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->total_column
Open

        if ($this->total_column) {
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->db
Open

            $this->db->order = $order;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->toggles
Open

            $max_tog = count($this->toggles);
Severity: Minor
Found in class/SubselectPager.php by phan

Call to method plugPageTags from undeclared class \DBPager
Open

        DBPager::plugPageTags($template);
Severity: Critical
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->orderby
Open

            $this->orderby = $orderby;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->db
Open

            $this->db->setLimit($this->getLimit());
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->db
Open

            $this->db->group_by = $group_by;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->total_column
Open

                        $this->total_column = $table . '.' . $index;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->sub_result
Open

        $this->sub_result['dbp' . $index] = array('sc' => $source_column,
Severity: Minor
Found in class/SubselectPager.php by phan

Suspicious array access to null
Open

        $join_match[$join_table] = array('jt' => $join_table,
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->anchor
Open

        if (empty($this->anchor)) {
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->db
Open

                $this->db->addWhere($column_name, $search, 'regexp', 'or', 1);
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->total_rows
Open

            $this->total_rows = & $count;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->default_order
Open

        if (!$order_set && isset($this->default_order)) {
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->default_order
Open

            $this->db->addOrder($this->default_order . ' ' . $this->default_order_dir);
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->limit
Open

            $cache['limit'] = $this->limit;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->link
Open

        $this->link = \PHPWS_Core::getCurrentUrl(true, false);
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->module
Open

        return PHPWS_Template::process($template, $this->module, $this->template);
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared constant \CSV_FULL
Open

            if ($this->report_type == XML_FULL || $this->report_type == CSV_FULL) {
Severity: Minor
Found in class/SubselectPager.php by phan

Variable $current_page is undeclared
Open

            $this->current_page = $current_page;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->default_limit
Open

                $this->limit = $this->default_limit;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->cache_identifier
Open

            extract($_SESSION['DB_Cache'][$this->module][$this->cache_identifier]);
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared constant \UTF8_MODE
Open

            if (UTF8_MODE) {
Severity: Minor
Found in class/SubselectPager.php by phan

Variable $limit is undeclared
Open

            $this->limit = $limit;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->orderby_dir
Open

            $this->orderby_dir = $orderby_dir;
Severity: Minor
Found in class/SubselectPager.php by phan

Call to method isError from undeclared class \PHPWS_Error
Open

        if (PHPWS_Error::isError($rows)) {
Severity: Critical
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->search
Open

            $this->search = $search;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->toggles
Open

        if (isset($this->toggles)) {
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->error
Open

        if (isset($this->error)) {
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->needed_columns
Open

        if (!empty($this->needed_columns)) {
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->db
Open

                $this->db->setLimit($this->getLimit());
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->needed_columns
Open

                $this->table_columns = array_merge($this->table_columns, $this->needed_columns);
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->display_rows
Open

        $this->display_rows = & $result;
Severity: Minor
Found in class/SubselectPager.php by phan

Variable $orderby is undeclared
Open

            $this->orderby = $orderby;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->db
Open

                    if ($index = $this->db->getIndex($table)) {
Severity: Minor
Found in class/SubselectPager.php by phan

Call to method getCurrentUrl from undeclared class \PHPWS_Core
Open

        $this->link = \PHPWS_Core::getCurrentUrl(true, false);
Severity: Critical
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->default_limit
Open

            if ($this->default_limit) {
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->orderby
Open

                $col_name = $this->orderby;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->default_order_dir
Open

            $this->db->addOrder($this->default_order . ' ' . $this->default_order_dir);
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->search (Did you mean $search)
Open

            $cache['search'] = $this->search;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->cache_identifier
Open

            $_SESSION['DB_Cache'][$this->module][$this->cache_identifier] = $cache;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->db
Open

            $this->db->order    = null;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->db
Open

            if (count($this->db->tables) > 1) {
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->error
Open

        return $this->error;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->sub_order
Open

        $this->sub_order[$new_name] = array('dbp' . $tbl_idx, $content_column);
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->needed_columns
Open

        $this->needed_columns[$new_name] = $new_name;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->anchor (Did you mean $anchor)
Open

        $this->anchor = $anchor;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->template (Did you mean $template)
Open

        return PHPWS_Template::process($template, $this->module, $this->template);
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->needed_columns
Open

                $this->table_columns = $this->needed_columns;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->table_columns
Open

                $this->table_columns = $this->needed_columns;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->search
Open

                empty($this->search) && isset($_SESSION['DB_Cache'][$this->module][$this->cache_identifier])) {
Severity: Minor
Found in class/SubselectPager.php by phan

Variable $search is undeclared
Open

            $this->search = $search;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->searchColumn
Open

        if (!$full_report && !empty($search) && isset($this->searchColumn)) {
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->db
Open

            $result = $this->db->select();
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->db
Open

            $result = $this->db->getObjects($this->class);
Severity: Minor
Found in class/SubselectPager.php by phan

Call to method isError from undeclared class \PHPWS_Error
Open

        if (PHPWS_Error::isError($result)) {
Severity: Critical
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->current_page
Open

            $cache['current_page'] = $this->current_page;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->db
Open

                foreach ($this->db->tables as $table) {
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->orderby
Open

        if ($only_if_empty && !empty($this->orderby)) {
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->db
Open

        $this->db = new SubselectDatabase($table);
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->module
Open

        if (!isset($this->module)) {
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->template (Did you mean $template)
Open

        if (!isset($this->template)) {
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->report_type
Open

            if ($this->report_type == XML_FULL || $this->report_type == CSV_FULL) {
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->limit
Open

            $this->limit = $limit;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->limit
Open

                $this->limit = $this->default_limit;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared constant \DBPAGER_DEFAULT_LIMIT
Open

                $this->limit = DBPAGER_DEFAULT_LIMIT;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->orderby
Open

        if (isset($this->orderby)) {
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->db
Open

            $this->db->group_by = null;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->db
Open

            $this->db->addColumn($this->total_column, null, null, true, true);
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->sub_search
Open

            $this->sub_search = true;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->orderby_dir
Open

        $this->orderby_dir = $direction;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->report_type
Open

        if ($this->report_type) {
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->report_type
Open

        if ($this->report_type && $this->report_row) {
Severity: Minor
Found in class/SubselectPager.php by phan

Call to method isError from undeclared class \PHPWS_Error
Open

        if (PHPWS_Error::isError($count)) {
Severity: Critical
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->final_template
Open

        $this->final_template = & $template;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->limit
Open

        if (!$full_report && $this->limit > 0) {
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->db
Open

        $this->table_columns = $this->db->getTableColumns();
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->limit
Open

            $this->total_pages = ceil($this->total_rows / $this->limit);
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->sub_order
Open

            if (isset($this->sub_order[$col_name]) && !empty($this->sub_order[$col_name])) {
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->table_columns
Open

                $this->table_columns = array_merge($this->table_columns, $this->needed_columns);
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->default_order (Did you mean $default_order)
Open

        $this->default_order = $default_order;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->cache_identifier
Open

            $this->cache_identifier = $this->template;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->limit
Open

        if (empty($this->limit) && empty($this->orderby) &&
Severity: Minor
Found in class/SubselectPager.php by phan

Variable $orderby_dir is undeclared
Open

            $this->orderby_dir = $orderby_dir;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->limit
Open

        if (empty($this->limit)) {
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->current_page
Open

                $this->current_page = $this->total_pages;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->orderby
Open

                $col_name = substr($this->orderby, $pos + 1);
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->sub_order
Open

                $orderby = implode('.', $this->sub_order[$col_name]);
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->db
Open

            $this->db->addOrder($orderby . ' ' . $this->orderby_dir);
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->class
Open

            $result = $this->db->getObjects($this->class);
Severity: Minor
Found in class/SubselectPager.php by phan

Call to method toString on non-class type true
Open

                throw new \Exception ($result->toString());
Severity: Critical
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->orderby (Did you mean $orderby)
Open

            $cache['orderby'] = $this->orderby;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->module
Open

            $_SESSION['DB_Cache'][$this->module][$this->cache_identifier] = $cache;
Severity: Minor
Found in class/SubselectPager.php by phan

Call to undeclared method \Intern\SubselectPager::getNavigation
Open

        $this->getNavigation($template);
Severity: Critical
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->cache_identifier
Open

        if (empty($this->cache_identifier)) {
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->db
Open

            $order = $this->db->order;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->db
Open

            $this->db->columns = $columns;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->searchColumn
Open

            foreach ($this->searchColumn as $column_name) {
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared constant \UTF8_MODE
Open

        if (UTF8_MODE) {
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->current_page
Open

            if ($this->current_page > $this->total_pages || $this->current_page == 'last') {
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->searchColumn
Open

                $this->searchColumn[] = $column;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->class
Open

        if (empty($this->class)) {
Severity: Minor
Found in class/SubselectPager.php by phan

Possibly zero references to use statement for classlike/namespace PHPWS_DB (\PHPWS_DB)
Open

use \PHPWS_DB;
Severity: Minor
Found in class/SubselectPager.php by phan

Class extends undeclared class \DBPager
Open

class SubselectPager extends \DBPager {
Severity: Critical
Found in class/SubselectPager.php by phan

Reference to undeclared constant \DBPAGER_TEMPLATE_NOT_SET
Open

            return PHPWS_Error::get(DBPAGER_TEMPLATE_NOT_SET, 'core', 'DBPager::get');
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->empty_message
Open

            $template['EMPTY_MESSAGE'] = $this->empty_message;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->current_page
Open

            $this->current_page = $current_page;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->total_pages
Open

            $this->total_pages = ceil($this->total_rows / $this->limit);
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->orderby
Open

                $orderby = $this->orderby;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->orderby_dir
Open

            $this->db->addOrder($orderby . ' ' . $this->orderby_dir);
Severity: Minor
Found in class/SubselectPager.php by phan

Variable $cache was undeclared, but array fields are being added to it.
Open

            $cache['limit'] = $this->limit;
Severity: Info
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->db
Open

            $this->db->columns  = null;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->row_tags
Open

        $this->row_tags = array('method' => $method, 'variable' => $variables);
Severity: Minor
Found in class/SubselectPager.php by phan

Call to method isError from undeclared class \PHPWS_Error
Open

            if (PHPWS_Error::isError($result)) {
Severity: Critical
Found in class/SubselectPager.php by phan

Call to method process from undeclared class \PHPWS_Template
Open

        return PHPWS_Template::process($template, $this->module, $this->template);
Severity: Critical
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->table_columns
Open

        $this->table_columns = $this->db->getTableColumns();
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared constant \XML_FULL
Open

            if ($this->report_type == XML_FULL || $this->report_type == CSV_FULL) {
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->module
Open

            extract($_SESSION['DB_Cache'][$this->module][$this->cache_identifier]);
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->orderby
Open

            if ($pos = strpos($this->orderby, '.')) {
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->db
Open

            $this->db->resetOrder();
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->db
Open

            $group_by = $this->db->group_by;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->db
Open

            $table = $this->db->getTable();
Severity: Minor
Found in class/SubselectPager.php by phan

Possibly zero references to use statement for classlike/namespace Exception (\Exception)
Open

use \Exception;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->report_row
Open

        if ($this->report_type && $this->report_row) {
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->toggles
Open

                        $rowitem['TOGGLE'] = $this->toggles[$count];
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->error
Open

            return $this->error;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->search
Open

        if ($this->search) {
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->search
Open

            $search = preg_replace('/\s/', '|', $this->search);
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->total_rows
Open

            $this->total_pages = ceil($this->total_rows / $this->limit);
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->total_pages
Open

            if ($this->current_page > $this->total_pages || $this->current_page == 'last') {
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared class \DBPager
Open

        parent::__construct($table, $class);
Severity: Critical
Found in class/SubselectPager.php by phan

Call to method get from undeclared class \PHPWS_Error
Open

            return PHPWS_Error::get(DBPAGER_TEMPLATE_NOT_SET, 'core', 'DBPager::get');
Severity: Critical
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->orderby (Did you mean $orderby)
Open

            $orderby = $this->orderby;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->toggles
Open

                            $rowitem['TOGGLE'] = $this->toggles[0];
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->template
Open

            $this->cache_identifier = $this->template;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->row_query
Open

        $this->row_query = $this->db->lastQuery();
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->module
Open

                empty($this->search) && isset($_SESSION['DB_Cache'][$this->module][$this->cache_identifier])) {
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->cache_queries
Open

        if ($this->cache_queries) {
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->db
Open

            $columns = $this->db->columns;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->orderby_dir
Open

            $cache['orderby_dir'] = $this->orderby_dir;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->db
Open

            $result = $this->db->count();
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->total_column
Open

            $this->db->addColumn($this->total_column, null, null, true, true);
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->search_label
Open

        $this->search_label = false;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->link (Did you mean $link)
Open

        $this->link = $link;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->search (Did you mean $search)
Open

        $this->search = & $search;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->db
Open

        return $this->db->addWhere($column, $value, $operator, $conj, $group);
Severity: Minor
Found in class/SubselectPager.php by phan

Call to method get from undeclared class \PHPWS_Error
Open

            return PHPWS_Error::get(DBPAGER_MODULE_NOT_SET, 'core', 'DBPager::get');
Severity: Critical
Found in class/SubselectPager.php by phan

Reference to undeclared constant \DBPAGER_MODULE_NOT_SET
Open

            return PHPWS_Error::get(DBPAGER_MODULE_NOT_SET, 'core', 'DBPager::get');
Severity: Minor
Found in class/SubselectPager.php by phan

Argument 1 (message) is ?array{0:array<string>|array<string>|array<string>}|?array{0:array<string>}|null</string></string></string></string> but \Exception::__construct() takes string
Open

            throw new \Exception($rows);
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->limit
Open

                $this->limit = DBPAGER_DEFAULT_LIMIT;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->total_pages
Open

                $this->current_page = $this->total_pages;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->class
Open

        if (empty($this->class)) {
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->toggles (Did you mean $toggle)
Open

        $this->toggles[] = $toggle;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->db
Open

        $this->db->setDistinct(true);
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->total_pages
Open

        if ($this->total_pages < 1) {
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared constant \DBPAGER_PAGE_LIMIT
Open

                $divider = DBPAGER_PAGE_LIMIT - 2;
Severity: Minor
Found in class/SubselectPager.php by phan

Call to method get from undeclared class \Icon
Open

                    $button = Icon::get('sort');
Severity: Critical
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->sort_headers
Open

            if (isset($this->sort_headers[$varname])) {
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->sort_headers
Open

        $this->sort_headers[$header]['hover'] = $hover;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->limit
Open

        if (empty($this->limit)) {
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->link
Open

        if (!empty($this->link)) {
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->class
Open

            if (isset($this->class) && isset($this->run_methods)) {
Severity: Minor
Found in class/SubselectPager.php by phan

Call to method setLabel from undeclared class \PHPWS_Form
Open

            $form->setLabel('pager_c_search', _('Search'));
Severity: Critical
Found in class/SubselectPager.php by phan

Call to method __construct from undeclared class \HTTP_Download
Open

        $dl = new \HTTP_Download;
Severity: Critical
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->convert_date
Open

        $this->convert_date[$column_name] = $format;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->anchor
Open

            return '#' . $this->anchor;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->page_turner_right
Open

        $this->page_turner_right = $turner;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->limit
Open

            $this->limit = $this->limitList[sizeof($this->limitList)-1];
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->limit
Open

        $start = ($this->current_page - 1) * $this->limit;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->total_column
Open

                $this->total_column = $table . '.' . trim($column);
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->db
Open

        $columns = $this->db->columns;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->total_pages
Open

            $total_pages = $this->total_pages;
Severity: Minor
Found in class/SubselectPager.php by phan

Call to method moduleLink from undeclared class \PHPWS_Text
Open

            $pageList[] = \PHPWS_Text::moduleLink('&gt;', $module, $values, null, _('Forward one page'));
Severity: Critical
Found in class/SubselectPager.php by phan

Call to method get from undeclared class \Icon
Open

                $button = Icon::get('sort');
Severity: Critical
Found in class/SubselectPager.php by phan

Reference to undeclared constant \UTF8_MODE
Open

        if (UTF8_MODE) {
Severity: Minor
Found in class/SubselectPager.php by phan

Call to method moduleLink from undeclared class \PHPWS_Text
Open

            $part = \PHPWS_Text::moduleLink(_('Partial'), $module, $values, null, _('Download a partial CSV file'));
Severity: Critical
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->class
Open

            if (isset($this->class)) {
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->row_tags
Open

                        $row_result = call_user_func_array(array($disp_row, $this->row_tags['method']), $this->row_tags['variable']);
Severity: Minor
Found in class/SubselectPager.php by phan

Call to method __construct from undeclared class \PHPWS_Form
Open

        $form = new \PHPWS_Form($id);
Severity: Critical
Found in class/SubselectPager.php by phan

Call to method getTemplate from undeclared class \PHPWS_Form
Open

        $template = $form->getTemplate();
Severity: Critical
Found in class/SubselectPager.php by phan

Call to method send from undeclared class \HTTP_Download
Open

        $dl->send();
Severity: Critical
Found in class/SubselectPager.php by phan

Call to method getCurrentUrl from undeclared class \PHPWS_Core
Open

        $_SESSION['DBPager_Last_View'][$this->table] = PHPWS_Core::getCurrentUrl();
Severity: Critical
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->link
Open

        return str_replace(strstr($this->link, '?'), '', $this->link);
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->db
Open

            if (!preg_match($preg, $column) && $this->db->isTableColumn($column)) {
Severity: Minor
Found in class/SubselectPager.php by phan

Call to method moduleLink from undeclared class \PHPWS_Text
Open

                    $pageList[] = \PHPWS_Text::moduleLink($j, $module, $values, null, sprintf(_('Go to page %s'), $j));
Severity: Critical
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->page_turner_left
Open

        $this->page_turner_left = $turner;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->sort_headers
Open

            $sort_columns = array_keys($this->sort_headers);
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared constant \DBPAGER_DEFAULT_LIMIT
Open

            $this->limit = DBPAGER_DEFAULT_LIMIT;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->empty_message
Open

        $this->empty_message = $message;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->orderby_dir
Open

            if (isset($this->orderby_dir))
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->toggle_func_number
Open

        $this->toggle_func_number = (int) $toggle;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->limitList
Open

        foreach ($this->limitList as $limit) {
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->current_page
Open

        $start = ($this->current_page - 1) * $this->limit;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->run_methods
Open

            if (isset($this->class) && isset($this->run_methods)) {
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->limit
Open

        return array((int) $this->limit, (int) $start);
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->db
Open

        $this->db->columns = null;
Severity: Minor
Found in class/SubselectPager.php by phan

Call to method get from undeclared class \PHPWS_Error
Open

                        return PHPWS_Error::get(DBPAGER_NO_METHOD, 'core', 'DBPager::getPageRows', $this->class . ':' . $this->row_tags['method']);
Severity: Critical
Found in class/SubselectPager.php by phan

Call to method randomString from undeclared class \PHPWS_Text
Open

        $tmp_file = \PHPWS_Text::randomString(10) . time();
Severity: Critical
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->table_columns
Open

        if (empty($this->table_columns)) {
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->cache_identifier
Open

        $this->cache_identifier = $str;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->module
Open

                $module = & $this->module;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared constant \DBPAGER_PAGE_LIMIT
Open

                        $front_skip = floor($total_pages / (DBPAGER_PAGE_LIMIT - 1));
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->module
Open

            $module = & $this->module;
Severity: Minor
Found in class/SubselectPager.php by phan

Call to method get from undeclared class \Icon
Open

                    $button = Icon::get('sort-down');
Severity: Critical
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->search
Open

        if (!empty($this->search)) {
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->convert_date
Open

                foreach ($this->convert_date as $key => $format) {
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->search
Open

            $values['pager_search'] = $this->search;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->row_tags
Open

                        $row_result = call_user_func(array($disp_row, $this->row_tags['method']));
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->display_rows
Open

        foreach ($this->display_rows as $disp_row) {
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->run_function (Did you mean $run_function)
Open

                    $row_result = call_user_func($this->run_function, $disp_row);
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared constant \DBPAGER_NO_METHOD
Open

                        return PHPWS_Error::get(DBPAGER_NO_METHOD, 'core', 'DBPager::getPageRows', $this->class . ':' . $this->row_tags['method']);
Severity: Minor
Found in class/SubselectPager.php by phan

Call to method addText from undeclared class \PHPWS_Form
Open

        $form->addText('pager_c_search', $this->search);
Severity: Critical
Found in class/SubselectPager.php by phan

Call to method setSize from undeclared class \PHPWS_Form
Open

        $form->setSize('pager_c_search', 20);
Severity: Critical
Found in class/SubselectPager.php by phan

Call to method stripObjValues from undeclared class \PHPWS_Core
Open

                    $result = PHPWS_Core::stripObjValues($foo);
Severity: Critical
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->table
Open

        $_SESSION['DBPager_Last_View'][$this->table] = PHPWS_Core::getCurrentUrl();
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->orderby
Open

        $this->orderby = preg_replace('/[^\w\.]/', '', $column);
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->default_order_dir
Open

        $this->default_order_dir = $direction;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->run_methods
Open

        $this->run_methods[] = $method;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->total_column
Open

            $this->total_column = trim($column);
Severity: Minor
Found in class/SubselectPager.php by phan

Call to method moduleLink from undeclared class \PHPWS_Text
Open

            $pageList[] = \PHPWS_Text::moduleLink($total_pages, $module, $values, null, _('Last page'));
Severity: Critical
Found in class/SubselectPager.php by phan

Call to method moduleLink from undeclared class \PHPWS_Text
Open

                $pageList[] = \PHPWS_Text::moduleLink('&gt;&gt;', $module, $values, null, _('Forward 10 pages'));
Severity: Critical
Found in class/SubselectPager.php by phan

Call to method moduleLink from undeclared class \PHPWS_Text
Open

                $pageList[] = \PHPWS_Text::moduleLink('&gt;&gt;&gt;', $module, $values, null, _('Forward 50 pages'));
Severity: Critical
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->sort_headers
Open

                    $alt = strip_tags($this->sort_headers[$varname]['title']) . ' - ';
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->orderby
Open

            if ($this->orderby == $varname) {
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->_class_vars
Open

                foreach ($this->_class_vars as $varname) {
Severity: Minor
Found in class/SubselectPager.php by phan

Suspicious array access to null
Open

                    $template[$count][strtoupper($varname)] = $disp_row->$varname;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->search
Open

        $form->addText('pager_c_search', $this->search);
Severity: Minor
Found in class/SubselectPager.php by phan

Call to method addSubmit from undeclared class \PHPWS_Form
Open

            $form->addSubmit('go', _('Search'));
Severity: Critical
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->report_row
Open

            if (function_exists($this->report_row)) {
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared constant \CACHE_DIRECTORY
Open

        $directory = CACHE_DIRECTORY;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->template
Open

            unset($_SESSION['DB_Cache'][$this->module][$this->template]);
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->default_limit
Open

        $this->default_limit = (int) $limit;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->limitList
Open

        if (empty($this->limit) || !in_array($this->limit, $this->limitList)) {
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->limitList
Open

            $this->limit = $this->limitList[sizeof($this->limitList)-1];
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->db
Open

        $group_by = $this->db->group_by;
Severity: Minor
Found in class/SubselectPager.php by phan

Call to method moduleLink from undeclared class \PHPWS_Text
Open

            $pageList[] = \PHPWS_Text::moduleLink('&lt;', $module, $values, null, _('Back one page'));
Severity: Critical
Found in class/SubselectPager.php by phan

Call to method get from undeclared class \Icon
Open

                    $button = Icon::get('sort-up');
Severity: Critical
Found in class/SubselectPager.php by phan

Call to method moduleLink from undeclared class \PHPWS_Text
Open

            $link = \PHPWS_Text::moduleLink($button_string, $module, $values, null, $alt);
Severity: Critical
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->sort_headers
Open

        $this->sort_headers[$header]['title'] = $title;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->module
Open

            $values['module'] = $this->module;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->display_rows
Open

        if (!isset($this->display_rows)) {
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->_methods
Open

                    if (!in_array($this->row_tags['method'], $this->_methods)) {
Severity: Minor
Found in class/SubselectPager.php by phan

Call to method setMethod from undeclared class \PHPWS_Form
Open

        $form->setMethod('get');
Severity: Critical
Found in class/SubselectPager.php by phan

Call to method addHidden from undeclared class \PHPWS_Form
Open

        $form->addHidden($values);
Severity: Critical
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->limitList
Open

        $this->limitList = $list;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->template (Did you mean $template)
Open

        $this->template = $template;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->db
Open

        $order = $this->db->order;
Severity: Minor
Found in class/SubselectPager.php by phan

Call to method moduleLink from undeclared class \PHPWS_Text
Open

                $pageList[] = \PHPWS_Text::moduleLink('&lt;&lt;', $module, $values, null, _('Back 10 pages'));
Severity: Critical
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->auto_sort
Open

        if ($this->auto_sort) {
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->current_page
Open

        $values['pg'] = $this->current_page;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->orderby
Open

            $values['orderby'] = $this->orderby;
Severity: Minor
Found in class/SubselectPager.php by phan

Call to method moduleLink from undeclared class \PHPWS_Text
Open

                $links[] = \PHPWS_Text::moduleLink($limit, $module, $values, null, sprintf(_('Limit results to %s rows'), $limit));
Severity: Critical
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->row_tags
Open

                    if (empty($this->row_tags['variable'])) {
Severity: Minor
Found in class/SubselectPager.php by phan

Suspicious array access to null
Open

                    $template[$count][strtoupper($key)] = $value;
Severity: Minor
Found in class/SubselectPager.php by phan

Call to method moduleLink from undeclared class \PHPWS_Text
Open

                    $pageList[] = \PHPWS_Text::moduleLink($i, $module, $values, null, sprintf(_('Go to page %s'), $i));
Severity: Critical
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->db
Open

        $this->db->group_by = $group_by;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->table_columns
Open

            $sort_columns = & $this->table_columns;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->link
Open

        return substr(strstr($this->link, '?'), 1);
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->link
Open

            $url = parse_url($this->link);
Severity: Minor
Found in class/SubselectPager.php by phan

Call to method moduleLink from undeclared class \PHPWS_Text
Open

            $pageList[] = \PHPWS_Text::moduleLink('1', $module, $values, null, _('First page'));
Severity: Critical
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->toggle_function
Open

            $this->toggle_function = $function;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->class
Open

                        return PHPWS_Error::get(DBPAGER_NO_METHOD, 'core', 'DBPager::getPageRows', $this->class . ':' . $this->row_tags['method']);
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->run_function
Open

            $this->run_function = $function;
Severity: Minor
Found in class/SubselectPager.php by phan

Argument 1 (function) is array{0:array|string[],1:mixed} but \call_user_func_array() takes callable
Open

                        $row_result = call_user_func_array(array($disp_row, $this->row_tags['method']), $this->row_tags['variable']);
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->run_function
Open

                $this->run_function = $function;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->_methods (Did you mean $method)
Open

        if (!in_array(strtolower($method), $this->_methods)) {
Severity: Minor
Found in class/SubselectPager.php by phan

Call to method setExtra from undeclared class \PHPWS_Form
Open

            $form->setExtra('clear', 'onclick="this.form.search_list_pager_c_search.value=\'\'"');
Severity: Critical
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->row_tags
Open

                        return PHPWS_Error::get(DBPAGER_NO_METHOD, 'core', 'DBPager::getPageRows', $this->class . ':' . $this->row_tags['method']);
Severity: Minor
Found in class/SubselectPager.php by phan

Call to method moduleLink from undeclared class \PHPWS_Text
Open

                $pageList[] = \PHPWS_Text::moduleLink('&lt;&lt;&lt;', $module, $values, null, _('Back 50 pages'));
Severity: Critical
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->class
Open

        if ($this->class) {
Severity: Minor
Found in class/SubselectPager.php by phan

Call to method isError from undeclared class \PHPWS_Error
Open

        if (PHPWS_Error::isError($template)) {
Severity: Critical
Found in class/SubselectPager.php by phan

Reference to undeclared constant \DBPAGER_PAGE_LIMIT
Open

        if ($total_pages > DBPAGER_PAGE_LIMIT) {
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->class
Open

            $methods = get_class_methods($this->class);
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->report_row
Open

                $result = call_user_func($this->report_row, $foo);
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared constant \HTTP_DOWNLOAD_ATTACHMENT
Open

        $dl->setContentDisposition(HTTP_DOWNLOAD_ATTACHMENT, $new_file);
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->class
Open

                    if ($this->class && isset($disp_row->$key)) {
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->display_rows
Open

        foreach ($this->display_rows as $foo) {
Severity: Minor
Found in class/SubselectPager.php by phan

Argument 1 (function) is array{0:array|string[],1:mixed} but \call_user_func() takes callable
Open

                    call_user_func(array($disp_row, $run_function));
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->final_template
Open

        return $this->final_template;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->row_tags
Open

                if (!empty($this->row_tags)) {
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->toggle_func_number
Open

                if (!($count % $this->toggle_func_number)) {
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->allow_partial_report
Open

        $this->allow_partial_report = (bool) $val;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->clear_button
Open

        if ($this->clear_button) {
Severity: Minor
Found in class/SubselectPager.php by phan

Call to method addButton from undeclared class \PHPWS_Form
Open

            $form->addButton('clear', _('Clear'));
Severity: Critical
Found in class/SubselectPager.php by phan

Call to method setFile from undeclared class \HTTP_Download
Open

        $dl->setFile($file_path);
Severity: Critical
Found in class/SubselectPager.php by phan

Call to method setContentType from undeclared class \HTTP_Download
Open

        $dl->setContentType('text/csv');
Severity: Critical
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->auto_sort
Open

        $this->auto_sort = (bool) $auto;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->page_tags
Open

        $this->page_tags = $tags;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->display_rows
Open

        return $this->display_rows;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->current_page
Open

            $current_page = $this->current_page;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared constant \DBPAGER_PAGE_LIMIT
Open

            $divider = floor(DBPAGER_PAGE_LIMIT / 2);
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->limit
Open

        $values['limit'] = $this->limit;
Severity: Minor
Found in class/SubselectPager.php by phan

Argument 1 (function) is array{0:array|string[],1:mixed} but \call_user_func() takes callable
Open

                        $row_result = call_user_func(array($disp_row, $this->row_tags['method']));
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->db
Open

        $this->db->columns = $columns;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->toggle_function
Open

            if (isset($this->toggle_function)) {
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->page_tags
Open

        if (isset($this->page_tags)) {
Severity: Minor
Found in class/SubselectPager.php by phan

Call to method moduleLink from undeclared class \PHPWS_Text
Open

                        $pageList[] = \PHPWS_Text::moduleLink($j, $module, $values, null, sprintf(_('Go to page %s'), $j));
Severity: Critical
Found in class/SubselectPager.php by phan

Argument 2 (pieces) is ?array|?array<int>|?array<int>|?array<int>|?array<int>|?array{}</int></int></int></int> but \implode() takes string[] when argument 1 is string
Open

        return implode(' ', $pageList);
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->orderby_dir
Open

                if ($this->orderby_dir == 'desc') {
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->limit
Open

            $this->limit = DBPAGER_DEFAULT_LIMIT;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->allow_partial_report
Open

        if ($this->allow_partial_report) {
Severity: Minor
Found in class/SubselectPager.php by phan

Call to method moduleLink from undeclared class \PHPWS_Text
Open

            $all = \PHPWS_Text::moduleLink(_('All'), $module, $values, null, _('Download a complete CSV file'));
Severity: Critical
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->row_tags
Open

                    if (!in_array($this->row_tags['method'], $this->_methods)) {
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->toggle_function
Open

                    $row_result = call_user_func($this->toggle_function, $disp_row);
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->search_button
Open

        if ($this->search_button) {
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->cache_queries
Open

        $this->cache_queries = (bool) $cache;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->module (Did you mean $module)
Open

        $this->module = $module;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->report_row (Did you mean $report_row)
Open

        $this->report_row = $report_row;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->toggle_function
Open

                $this->toggle_function = $function;
Severity: Minor
Found in class/SubselectPager.php by phan

Variable $pageList was undeclared, but array fields are being added to it.
Open

            $pageList[] = '[1]';
Severity: Info
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->db
Open

        $result = $this->db->select('count');
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->sort_headers
Open

            if (isset($this->sort_headers[$varname])) {
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->db
Open

        $this->db->order = $order;
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->sort_headers
Open

                if (!empty($this->sort_headers[$varname]['hover'])) {
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->sort_headers
Open

                    $alt = strip_tags($this->sort_headers[$varname]['hover']) . ' - ';
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->orderby_dir
Open

                $values['orderby_dir'] = $this->orderby_dir;
Severity: Minor
Found in class/SubselectPager.php by phan

Call to method getGetValues from undeclared class \PHPWS_Text
Open

        $extra = \PHPWS_Text::getGetValues();
Severity: Critical
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->orderby_dir
Open

                } elseif ($this->orderby_dir == "asc") {
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->convert_date
Open

            if (!empty($this->convert_date)) {
Severity: Minor
Found in class/SubselectPager.php by phan

Call to method log from undeclared class \PHPWS_Error
Open

            PHPWS_Error::log($template);
Severity: Critical
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->report_row
Open

            if (in_array($this->report_row, $methods)) {
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->sort_headers
Open

                $button_string .= $this->sort_headers[$varname]['title'];
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->orderby
Open

        if (isset($this->orderby)) {
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->limit (Did you mean $limit)
Open

            if ($limit == $this->limit) {
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->run_methods
Open

                foreach ($this->run_methods as $run_function) {
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->run_function (Did you mean $run_function)
Open

                if (isset($this->run_function)) {
Severity: Minor
Found in class/SubselectPager.php by phan

Call to method setContentDisposition from undeclared class \HTTP_Download
Open

        $dl->setContentDisposition(HTTP_DOWNLOAD_ATTACHMENT, $new_file);
Severity: Critical
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->module
Open

            unset($_SESSION['DB_Cache'][$this->module][$this->template]);
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->limit
Open

        if (empty($this->limit) || !in_array($this->limit, $this->limitList)) {
Severity: Minor
Found in class/SubselectPager.php by phan

Call to method moduleLink from undeclared class \PHPWS_Text
Open

                            $pageList[] = \PHPWS_Text::moduleLink($i, $module, $values, null, sprintf(_('Go to page %s'), $i));
Severity: Critical
Found in class/SubselectPager.php by phan

Call to method moduleLink from undeclared class \PHPWS_Text
Open

                    $pageList[] = \PHPWS_Text::moduleLink($j, $module, $values, null, sprintf(_('Go to page %s'), $j));
Severity: Critical
Found in class/SubselectPager.php by phan

Call to method moduleLink from undeclared class \PHPWS_Text
Open

            return \PHPWS_Text::moduleLink(_('CSV Report'), $module, $values, null, _('Download a complete CSV file'));
Severity: Critical
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->search_label
Open

        if ($this->search_label) {
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->report_row
Open

                $result = call_user_func(array($foo, $this->report_row));
Severity: Minor
Found in class/SubselectPager.php by phan

Reference to undeclared property \Intern\SubselectPager->page_tags
Open

            foreach ($this->page_tags as $key => $value)
Severity: Minor
Found in class/SubselectPager.php by phan

Similar blocks of code found in 2 locations. Consider refactoring.
Open

        if (is_string($function) && function_exists($function)) {
            $this->toggle_function = $function;
            return true;
        } elseif (is_array($function) && class_exists($function[0])) {
            if (version_compare(phpversion(), '5.0.0', '<')) {
Severity: Major
Found in class/SubselectPager.php and 1 other location - About 4 hrs to fix
class/SubselectPager.php on lines 662..680

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 177.

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

Further Reading

Similar blocks of code found in 2 locations. Consider refactoring.
Open

        if (is_string($function) && function_exists($function)) {
            $this->run_function = $function;
            return true;
        } elseif (is_array($function) && class_exists($function[0])) {
            if (version_compare(phpversion(), '5.0.0', '<')) {
Severity: Major
Found in class/SubselectPager.php and 1 other location - About 4 hrs to fix
class/SubselectPager.php on lines 636..654

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 177.

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

Further Reading

The parameter $source_column is not named in camelCase.
Open

    public function joinResult($source_column, $join_table, $join_column, $content_column, $new_name=null, $searchable=false)
    {
        // TODO: this will break if you have more than one db pager at a time
        // TODO: make this a private member variable
        static $join_match = null;
Severity: Minor
Found in class/SubselectPager.php by phpmd

CamelCaseParameterName

Since: 0.2

It is considered best practice to use the camelCase notation to name parameters.

Example

class ClassName {
    public function doSomething($user_name) {
    }
}

Source

The parameter $content_column is not named in camelCase.
Open

    public function joinResult($source_column, $join_table, $join_column, $content_column, $new_name=null, $searchable=false)
    {
        // TODO: this will break if you have more than one db pager at a time
        // TODO: make this a private member variable
        static $join_match = null;
Severity: Minor
Found in class/SubselectPager.php by phpmd

CamelCaseParameterName

Since: 0.2

It is considered best practice to use the camelCase notation to name parameters.

Example

class ClassName {
    public function doSomething($user_name) {
    }
}

Source

Avoid variables with short names like $dl. Configured minimum length is 3.
Open

        $dl = new \HTTP_Download;
Severity: Minor
Found in class/SubselectPager.php by phpmd

ShortVariable

Since: 0.2

Detects when a field, local, or parameter has a very short name.

Example

class Something {
    private $q = 15; // VIOLATION - Field
    public static function main( array $as ) { // VIOLATION - Formal
        $r = 20 + $this->q; // VIOLATION - Local
        for (int $i = 0; $i < 10; $i++) { // Not a Violation (inside FOR)
            $r += $this->q;
        }
    }
}

Source https://phpmd.org/rules/naming.html#shortvariable

The parameter $column_name is not named in camelCase.
Open

    public function convertDate($column_name, $format='%c')
    {
        $this->convert_date[$column_name] = $format;
    }
Severity: Minor
Found in class/SubselectPager.php by phpmd

CamelCaseParameterName

Since: 0.2

It is considered best practice to use the camelCase notation to name parameters.

Example

class ClassName {
    public function doSomething($user_name) {
    }
}

Source

The parameter $return_blank_results is not named in camelCase.
Open

    public function get($return_blank_results=true)
    {
        $template = array();

        if (empty($this->display_rows)) {
Severity: Minor
Found in class/SubselectPager.php by phpmd

CamelCaseParameterName

Since: 0.2

It is considered best practice to use the camelCase notation to name parameters.

Example

class ClassName {
    public function doSomething($user_name) {
    }
}

Source

The parameter $join_column is not named in camelCase.
Open

    public function joinResult($source_column, $join_table, $join_column, $content_column, $new_name=null, $searchable=false)
    {
        // TODO: this will break if you have more than one db pager at a time
        // TODO: make this a private member variable
        static $join_match = null;
Severity: Minor
Found in class/SubselectPager.php by phpmd

CamelCaseParameterName

Since: 0.2

It is considered best practice to use the camelCase notation to name parameters.

Example

class ClassName {
    public function doSomething($user_name) {
    }
}

Source

The parameter $new_name is not named in camelCase.
Open

    public function joinResult($source_column, $join_table, $join_column, $content_column, $new_name=null, $searchable=false)
    {
        // TODO: this will break if you have more than one db pager at a time
        // TODO: make this a private member variable
        static $join_match = null;
Severity: Minor
Found in class/SubselectPager.php by phpmd

CamelCaseParameterName

Since: 0.2

It is considered best practice to use the camelCase notation to name parameters.

Example

class ClassName {
    public function doSomething($user_name) {
    }
}

Source

The parameter $only_if_empty is not named in camelCase.
Open

    public function setOrder($column, $direction='asc', $only_if_empty=false)
    {
        if ($only_if_empty && !empty($this->orderby)) {
            return;
        }
Severity: Minor
Found in class/SubselectPager.php by phpmd

CamelCaseParameterName

Since: 0.2

It is considered best practice to use the camelCase notation to name parameters.

Example

class ClassName {
    public function doSomething($user_name) {
    }
}

Source

The parameter $join_table is not named in camelCase.
Open

    public function joinResult($source_column, $join_table, $join_column, $content_column, $new_name=null, $searchable=false)
    {
        // TODO: this will break if you have more than one db pager at a time
        // TODO: make this a private member variable
        static $join_match = null;
Severity: Minor
Found in class/SubselectPager.php by phpmd

CamelCaseParameterName

Since: 0.2

It is considered best practice to use the camelCase notation to name parameters.

Example

class ClassName {
    public function doSomething($user_name) {
    }
}

Source

The parameter $report_row is not named in camelCase.
Open

    public function setReportRow($report_row)
    {
        $this->report_row = $report_row;
    }
Severity: Minor
Found in class/SubselectPager.php by phpmd

CamelCaseParameterName

Since: 0.2

It is considered best practice to use the camelCase notation to name parameters.

Example

class ClassName {
    public function doSomething($user_name) {
    }
}

Source

The parameter $load_rows is not named in camelCase.
Open

    public function initialize($load_rows=true)
    {
        $order_set = false;
        $this->table_columns = $this->db->getTableColumns();

Severity: Minor
Found in class/SubselectPager.php by phpmd

CamelCaseParameterName

Since: 0.2

It is considered best practice to use the camelCase notation to name parameters.

Example

class ClassName {
    public function doSomething($user_name) {
    }
}

Source

The parameter $default_order is not named in camelCase.
Open

    public function setDefaultOrder($default_order, $direction='asc')
    {
        if (preg_match('/\W/', $default_order)) {
            return false;
        }
Severity: Minor
Found in class/SubselectPager.php by phpmd

CamelCaseParameterName

Since: 0.2

It is considered best practice to use the camelCase notation to name parameters.

Example

class ClassName {
    public function doSomething($user_name) {
    }
}

Source

Avoid variables with short names like $id. Configured minimum length is 3.
Open

            $id = 'search_list_' . $id_count;
Severity: Minor
Found in class/SubselectPager.php by phpmd

ShortVariable

Since: 0.2

Detects when a field, local, or parameter has a very short name.

Example

class Something {
    private $q = 15; // VIOLATION - Field
    public static function main( array $as ) { // VIOLATION - Formal
        $r = 20 + $this->q; // VIOLATION - Local
        for (int $i = 0; $i < 10; $i++) { // Not a Violation (inside FOR)
            $r += $this->q;
        }
    }
}

Source https://phpmd.org/rules/naming.html#shortvariable

Avoid variables with short names like $fp. Configured minimum length is 3.
Open

        $fp = fopen($file_path, 'w');
Severity: Minor
Found in class/SubselectPager.php by phpmd

ShortVariable

Since: 0.2

Detects when a field, local, or parameter has a very short name.

Example

class Something {
    private $q = 15; // VIOLATION - Field
    public static function main( array $as ) { // VIOLATION - Formal
        $r = 20 + $this->q; // VIOLATION - Local
        for (int $i = 0; $i < 10; $i++) { // Not a Violation (inside FOR)
            $r += $this->q;
        }
    }
}

Source https://phpmd.org/rules/naming.html#shortvariable

The variable $full_report is not named in camelCase.
Open

    public function initialize($load_rows=true)
    {
        $order_set = false;
        $this->table_columns = $this->db->getTableColumns();

Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $col_name is not named in camelCase.
Open

    public function initialize($load_rows=true)
    {
        $order_set = false;
        $this->table_columns = $this->db->getTableColumns();

Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $col_name is not named in camelCase.
Open

    public function initialize($load_rows=true)
    {
        $order_set = false;
        $this->table_columns = $this->db->getTableColumns();

Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $order_set is not named in camelCase.
Open

    public function initialize($load_rows=true)
    {
        $order_set = false;
        $this->table_columns = $this->db->getTableColumns();

Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $join_table is not named in camelCase.
Open

    public function joinResult($source_column, $join_table, $join_column, $content_column, $new_name=null, $searchable=false)
    {
        // TODO: this will break if you have more than one db pager at a time
        // TODO: make this a private member variable
        static $join_match = null;
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $join_column is not named in camelCase.
Open

    public function joinResult($source_column, $join_table, $join_column, $content_column, $new_name=null, $searchable=false)
    {
        // TODO: this will break if you have more than one db pager at a time
        // TODO: make this a private member variable
        static $join_match = null;
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $tbl_idx is not named in camelCase.
Open

    public function joinResult($source_column, $join_table, $join_column, $content_column, $new_name=null, $searchable=false)
    {
        // TODO: this will break if you have more than one db pager at a time
        // TODO: make this a private member variable
        static $join_match = null;
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $current_page is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $total_pages is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $sort_columns is not named in camelCase.
Open

    public function getSortButtons(&$template)
    {
        if (empty($this->table_columns)) {
            return null;
        }
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $search_val is not named in camelCase.
Open

    public function getLinkValues()
    {
        $output = null;
        if (isset($GLOBALS['DBPager_Link_Values'])) {
            return $GLOBALS['DBPager_Link_Values'];
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $row_result is not named in camelCase.
Open

    public function getPageRows()
    {
        $template = null;
        $count = 0;

Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $column_name is not named in camelCase.
Open

    public function convertDate($column_name, $format='%c')
    {
        $this->convert_date[$column_name] = $format;
    }
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $full_report is not named in camelCase.
Open

    public function initialize($load_rows=true)
    {
        $order_set = false;
        $this->table_columns = $this->db->getTableColumns();

Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $column_name is not named in camelCase.
Open

    public function initialize($load_rows=true)
    {
        $order_set = false;
        $this->table_columns = $this->db->getTableColumns();

Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $tbl_idx is not named in camelCase.
Open

    public function joinResult($source_column, $join_table, $join_column, $content_column, $new_name=null, $searchable=false)
    {
        // TODO: this will break if you have more than one db pager at a time
        // TODO: make this a private member variable
        static $join_match = null;
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $content_column is not named in camelCase.
Open

    public function joinResult($source_column, $join_table, $join_column, $content_column, $new_name=null, $searchable=false)
    {
        // TODO: this will break if you have more than one db pager at a time
        // TODO: make this a private member variable
        static $join_match = null;
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $col_list is not named in camelCase.
Open

    public function setSearch()
    {
        $args = func_get_args();

        if (sizeof($args) == 1 && is_array($args[0])) {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $col_list is not named in camelCase.
Open

    public function setSearch()
    {
        $args = func_get_args();

        if (sizeof($args) == 1 && is_array($args[0])) {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $current_page is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $current_page is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $current_page is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $current_page is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $front_skip is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $front_skip is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $front_skip is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $back_skip is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $button_string is not named in camelCase.
Open

    public function getSortButtons(&$template)
    {
        if (empty($this->table_columns)) {
            return null;
        }
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $disp_row is not named in camelCase.
Open

    public function getPageRows()
    {
        $template = null;
        $count = 0;

Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $row_result is not named in camelCase.
Open

    public function getPageRows()
    {
        $template = null;
        $count = 0;

Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $row_result is not named in camelCase.
Open

    public function getPageRows()
    {
        $template = null;
        $count = 0;

Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $index_set is not named in camelCase.
Open

    function createReport()
    {
        if ($this->class) {
            $methods = get_class_methods($this->class);
            if (in_array($this->report_row, $methods)) {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $file_path is not named in camelCase.
Open

    function createReport()
    {
        if ($this->class) {
            $methods = get_class_methods($this->class);
            if (in_array($this->report_row, $methods)) {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $join_array is not named in camelCase.
Open

    public function joinResult($source_column, $join_table, $join_column, $content_column, $new_name=null, $searchable=false)
    {
        // TODO: this will break if you have more than one db pager at a time
        // TODO: make this a private member variable
        static $join_match = null;
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $current_page is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $remaining_pages is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $front_skip is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $beginning_pages is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $remaining_pages is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $current_page is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $current_page is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $total_pages is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $current_page is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $sort_columns is not named in camelCase.
Open

    public function getSortButtons(&$template)
    {
        if (empty($this->table_columns)) {
            return null;
        }
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $col_name is not named in camelCase.
Open

    public function initialize($load_rows=true)
    {
        $order_set = false;
        $this->table_columns = $this->db->getTableColumns();

Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $search_val is not named in camelCase.
Open

    public function getLinkValues()
    {
        $output = null;
        if (isset($GLOBALS['DBPager_Link_Values'])) {
            return $GLOBALS['DBPager_Link_Values'];
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $join_match is not named in camelCase.
Open

    public function joinResult($source_column, $join_table, $join_column, $content_column, $new_name=null, $searchable=false)
    {
        // TODO: this will break if you have more than one db pager at a time
        // TODO: make this a private member variable
        static $join_match = null;
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $disp_row is not named in camelCase.
Open

    public function getPageRows()
    {
        $template = null;
        $count = 0;

Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $join_column is not named in camelCase.
Open

    public function joinResult($source_column, $join_table, $join_column, $content_column, $new_name=null, $searchable=false)
    {
        // TODO: this will break if you have more than one db pager at a time
        // TODO: make this a private member variable
        static $join_match = null;
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $disp_row is not named in camelCase.
Open

    public function getPageRows()
    {
        $template = null;
        $count = 0;

Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $join_table is not named in camelCase.
Open

    public function joinResult($source_column, $join_table, $join_column, $content_column, $new_name=null, $searchable=false)
    {
        // TODO: this will break if you have more than one db pager at a time
        // TODO: make this a private member variable
        static $join_match = null;
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $row_result is not named in camelCase.
Open

    public function getPageRows()
    {
        $template = null;
        $count = 0;

Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $join_table is not named in camelCase.
Open

    public function joinResult($source_column, $join_table, $join_column, $content_column, $new_name=null, $searchable=false)
    {
        // TODO: this will break if you have more than one db pager at a time
        // TODO: make this a private member variable
        static $join_match = null;
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $func_type is not named in camelCase.
Open

    function createReport()
    {
        if ($this->class) {
            $methods = get_class_methods($this->class);
            if (in_array($this->report_row, $methods)) {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $file_path is not named in camelCase.
Open

    function createReport()
    {
        if ($this->class) {
            $methods = get_class_methods($this->class);
            if (in_array($this->report_row, $methods)) {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $total_pages is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $max_tog is not named in camelCase.
Open

    public function get($return_blank_results=true)
    {
        $template = array();

        if (empty($this->display_rows)) {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $current_page is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $current_page is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $total_pages is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $join_table is not named in camelCase.
Open

    public function joinResult($source_column, $join_table, $join_column, $content_column, $new_name=null, $searchable=false)
    {
        // TODO: this will break if you have more than one db pager at a time
        // TODO: make this a private member variable
        static $join_match = null;
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $current_page is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $tbl_idx is not named in camelCase.
Open

    public function joinResult($source_column, $join_table, $join_column, $content_column, $new_name=null, $searchable=false)
    {
        // TODO: this will break if you have more than one db pager at a time
        // TODO: make this a private member variable
        static $join_match = null;
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $new_name is not named in camelCase.
Open

    public function joinResult($source_column, $join_table, $join_column, $content_column, $new_name=null, $searchable=false)
    {
        // TODO: this will break if you have more than one db pager at a time
        // TODO: make this a private member variable
        static $join_match = null;
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $only_if_empty is not named in camelCase.
Open

    public function setOrder($column, $direction='asc', $only_if_empty=false)
    {
        if ($only_if_empty && !empty($this->orderby)) {
            return;
        }
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $report_row is not named in camelCase.
Open

    public function setReportRow($report_row)
    {
        $this->report_row = $report_row;
    }
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $remaining_pages is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $run_function is not named in camelCase.
Open

    public function getPageRows()
    {
        $template = null;
        $count = 0;

Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $order_set is not named in camelCase.
Open

    public function initialize($load_rows=true)
    {
        $order_set = false;
        $this->table_columns = $this->db->getTableColumns();

Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $remaining_pages is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $row_result is not named in camelCase.
Open

    public function getPageRows()
    {
        $template = null;
        $count = 0;

Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $order_set is not named in camelCase.
Open

    public function initialize($load_rows=true)
    {
        $order_set = false;
        $this->table_columns = $this->db->getTableColumns();

Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $total_pages is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $row_result is not named in camelCase.
Open

    public function getPageRows()
    {
        $template = null;
        $count = 0;

Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $back_skip is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $id_count is not named in camelCase.
Open

    public function getSearchBox()
    {
        static $id_count = 0;

        if ($id_count) {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $back_skip is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $total_pages is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $join_match is not named in camelCase.
Open

    public function joinResult($source_column, $join_table, $join_column, $content_column, $new_name=null, $searchable=false)
    {
        // TODO: this will break if you have more than one db pager at a time
        // TODO: make this a private member variable
        static $join_match = null;
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $tbl_idx is not named in camelCase.
Open

    public function joinResult($source_column, $join_table, $join_column, $content_column, $new_name=null, $searchable=false)
    {
        // TODO: this will break if you have more than one db pager at a time
        // TODO: make this a private member variable
        static $join_match = null;
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $func_type is not named in camelCase.
Open

    function createReport()
    {
        if ($this->class) {
            $methods = get_class_methods($this->class);
            if (in_array($this->report_row, $methods)) {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $join_array is not named in camelCase.
Open

    public function joinResult($source_column, $join_table, $join_column, $content_column, $new_name=null, $searchable=false)
    {
        // TODO: this will break if you have more than one db pager at a time
        // TODO: make this a private member variable
        static $join_match = null;
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $col_list is not named in camelCase.
Open

    public function setSearch()
    {
        $args = func_get_args();

        if (sizeof($args) == 1 && is_array($args[0])) {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $search_val is not named in camelCase.
Open

    public function getLinkValues()
    {
        $output = null;
        if (isset($GLOBALS['DBPager_Link_Values'])) {
            return $GLOBALS['DBPager_Link_Values'];
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $disp_row is not named in camelCase.
Open

    public function getPageRows()
    {
        $template = null;
        $count = 0;

Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $row_result is not named in camelCase.
Open

    public function getPageRows()
    {
        $template = null;
        $count = 0;

Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $total_pages is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $remaining_pages is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $index_set is not named in camelCase.
Open

    function createReport()
    {
        if ($this->class) {
            $methods = get_class_methods($this->class);
            if (in_array($this->report_row, $methods)) {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $current_page is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $current_page is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $search_val is not named in camelCase.
Open

    public function getLinkValues()
    {
        $output = null;
        if (isset($GLOBALS['DBPager_Link_Values'])) {
            return $GLOBALS['DBPager_Link_Values'];
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $run_function is not named in camelCase.
Open

    public function getPageRows()
    {
        $template = null;
        $count = 0;

Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $disp_row is not named in camelCase.
Open

    public function getPageRows()
    {
        $template = null;
        $count = 0;

Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $row_result is not named in camelCase.
Open

    public function getPageRows()
    {
        $template = null;
        $count = 0;

Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $func_type is not named in camelCase.
Open

    function createReport()
    {
        if ($this->class) {
            $methods = get_class_methods($this->class);
            if (in_array($this->report_row, $methods)) {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $func_type is not named in camelCase.
Open

    function createReport()
    {
        if ($this->class) {
            $methods = get_class_methods($this->class);
            if (in_array($this->report_row, $methods)) {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $func_type is not named in camelCase.
Open

    function createReport()
    {
        if ($this->class) {
            $methods = get_class_methods($this->class);
            if (in_array($this->report_row, $methods)) {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $join_table is not named in camelCase.
Open

    public function joinResult($source_column, $join_table, $join_column, $content_column, $new_name=null, $searchable=false)
    {
        // TODO: this will break if you have more than one db pager at a time
        // TODO: make this a private member variable
        static $join_match = null;
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $source_column is not named in camelCase.
Open

    public function joinResult($source_column, $join_table, $join_column, $content_column, $new_name=null, $searchable=false)
    {
        // TODO: this will break if you have more than one db pager at a time
        // TODO: make this a private member variable
        static $join_match = null;
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $default_order is not named in camelCase.
Open

    public function setDefaultOrder($default_order, $direction='asc')
    {
        if (preg_match('/\W/', $default_order)) {
            return false;
        }
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $current_page is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $row_result is not named in camelCase.
Open

    public function getPageRows()
    {
        $template = null;
        $count = 0;

Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $row_result is not named in camelCase.
Open

    public function getPageRows()
    {
        $template = null;
        $count = 0;

Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $id_count is not named in camelCase.
Open

    public function getSearchBox()
    {
        static $id_count = 0;

        if ($id_count) {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $tmp_file is not named in camelCase.
Open

    function createReport()
    {
        if ($this->class) {
            $methods = get_class_methods($this->class);
            if (in_array($this->report_row, $methods)) {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $join_array is not named in camelCase.
Open

    public function joinResult($source_column, $join_table, $join_column, $content_column, $new_name=null, $searchable=false)
    {
        // TODO: this will break if you have more than one db pager at a time
        // TODO: make this a private member variable
        static $join_match = null;
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $source_column is not named in camelCase.
Open

    public function joinResult($source_column, $join_table, $join_column, $content_column, $new_name=null, $searchable=false)
    {
        // TODO: this will break if you have more than one db pager at a time
        // TODO: make this a private member variable
        static $join_match = null;
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $join_array is not named in camelCase.
Open

    public function joinResult($source_column, $join_table, $join_column, $content_column, $new_name=null, $searchable=false)
    {
        // TODO: this will break if you have more than one db pager at a time
        // TODO: make this a private member variable
        static $join_match = null;
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $join_array is not named in camelCase.
Open

    public function joinResult($source_column, $join_table, $join_column, $content_column, $new_name=null, $searchable=false)
    {
        // TODO: this will break if you have more than one db pager at a time
        // TODO: make this a private member variable
        static $join_match = null;
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $new_name is not named in camelCase.
Open

    public function joinResult($source_column, $join_table, $join_column, $content_column, $new_name=null, $searchable=false)
    {
        // TODO: this will break if you have more than one db pager at a time
        // TODO: make this a private member variable
        static $join_match = null;
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $new_name is not named in camelCase.
Open

    public function joinResult($source_column, $join_table, $join_column, $content_column, $new_name=null, $searchable=false)
    {
        // TODO: this will break if you have more than one db pager at a time
        // TODO: make this a private member variable
        static $join_match = null;
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $join_match is not named in camelCase.
Open

    public function joinResult($source_column, $join_table, $join_column, $content_column, $new_name=null, $searchable=false)
    {
        // TODO: this will break if you have more than one db pager at a time
        // TODO: make this a private member variable
        static $join_match = null;
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $group_by is not named in camelCase.
Open

    public function fullRowCount()
    {
        $this->db->setDistinct(true);
        $order = $this->db->order;
        $columns = $this->db->columns;
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $total_pages is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $content_column is not named in camelCase.
Open

    public function joinResult($source_column, $join_table, $join_column, $content_column, $new_name=null, $searchable=false)
    {
        // TODO: this will break if you have more than one db pager at a time
        // TODO: make this a private member variable
        static $join_match = null;
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $back_skip is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $total_pages is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $current_page is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $current_page is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $total_pages is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $back_skip is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $total_pages is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $total_pages is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $id_count is not named in camelCase.
Open

    public function getSearchBox()
    {
        static $id_count = 0;

        if ($id_count) {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $index_set is not named in camelCase.
Open

    function createReport()
    {
        if ($this->class) {
            $methods = get_class_methods($this->class);
            if (in_array($this->report_row, $methods)) {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $max_tog is not named in camelCase.
Open

    public function get($return_blank_results=true)
    {
        $template = array();

        if (empty($this->display_rows)) {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $max_tog is not named in camelCase.
Open

    public function get($return_blank_results=true)
    {
        $template = array();

        if (empty($this->display_rows)) {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $button_string is not named in camelCase.
Open

    public function getSortButtons(&$template)
    {
        if (empty($this->table_columns)) {
            return null;
        }
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $full_report is not named in camelCase.
Open

    public function initialize($load_rows=true)
    {
        $order_set = false;
        $this->table_columns = $this->db->getTableColumns();

Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $button_string is not named in camelCase.
Open

    public function getSortButtons(&$template)
    {
        if (empty($this->table_columns)) {
            return null;
        }
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $search_val is not named in camelCase.
Open

    public function getLinkValues()
    {
        $output = null;
        if (isset($GLOBALS['DBPager_Link_Values'])) {
            return $GLOBALS['DBPager_Link_Values'];
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $disp_row is not named in camelCase.
Open

    public function getPageRows()
    {
        $template = null;
        $count = 0;

Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $disp_row is not named in camelCase.
Open

    public function getPageRows()
    {
        $template = null;
        $count = 0;

Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $content_column is not named in camelCase.
Open

    public function joinResult($source_column, $join_table, $join_column, $content_column, $new_name=null, $searchable=false)
    {
        // TODO: this will break if you have more than one db pager at a time
        // TODO: make this a private member variable
        static $join_match = null;
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $join_table is not named in camelCase.
Open

    public function joinResult($source_column, $join_table, $join_column, $content_column, $new_name=null, $searchable=false)
    {
        // TODO: this will break if you have more than one db pager at a time
        // TODO: make this a private member variable
        static $join_match = null;
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $file_path is not named in camelCase.
Open

    function createReport()
    {
        if ($this->class) {
            $methods = get_class_methods($this->class);
            if (in_array($this->report_row, $methods)) {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $default_order is not named in camelCase.
Open

    public function setDefaultOrder($default_order, $direction='asc')
    {
        if (preg_match('/\W/', $default_order)) {
            return false;
        }
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $group_by is not named in camelCase.
Open

    public function fullRowCount()
    {
        $this->db->setDistinct(true);
        $order = $this->db->order;
        $columns = $this->db->columns;
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $current_page is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $current_page is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $remaining_pages is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $remaining_pages is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $front_skip is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $disp_row is not named in camelCase.
Open

    public function getPageRows()
    {
        $template = null;
        $count = 0;

Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $row_result is not named in camelCase.
Open

    public function getPageRows()
    {
        $template = null;
        $count = 0;

Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $column_name is not named in camelCase.
Open

    public function initialize($load_rows=true)
    {
        $order_set = false;
        $this->table_columns = $this->db->getTableColumns();

Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $current_page is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $total_pages is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $current_page is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $disp_row is not named in camelCase.
Open

    public function getPageRows()
    {
        $template = null;
        $count = 0;

Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $disp_row is not named in camelCase.
Open

    public function getPageRows()
    {
        $template = null;
        $count = 0;

Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $row_result is not named in camelCase.
Open

    public function getPageRows()
    {
        $template = null;
        $count = 0;

Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $full_report is not named in camelCase.
Open

    public function initialize($load_rows=true)
    {
        $order_set = false;
        $this->table_columns = $this->db->getTableColumns();

Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $join_column is not named in camelCase.
Open

    public function joinResult($source_column, $join_table, $join_column, $content_column, $new_name=null, $searchable=false)
    {
        // TODO: this will break if you have more than one db pager at a time
        // TODO: make this a private member variable
        static $join_match = null;
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $tmp_file is not named in camelCase.
Open

    function createReport()
    {
        if ($this->class) {
            $methods = get_class_methods($this->class);
            if (in_array($this->report_row, $methods)) {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $current_page is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $current_page is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $beginning_pages is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $beginning_pages is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $total_pages is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $sort_columns is not named in camelCase.
Open

    public function getSortButtons(&$template)
    {
        if (empty($this->table_columns)) {
            return null;
        }
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $disp_row is not named in camelCase.
Open

    public function getPageRows()
    {
        $template = null;
        $count = 0;

Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $index_keys is not named in camelCase.
Open

    function createReport()
    {
        if ($this->class) {
            $methods = get_class_methods($this->class);
            if (in_array($this->report_row, $methods)) {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $new_file is not named in camelCase.
Open

    function createReport()
    {
        if ($this->class) {
            $methods = get_class_methods($this->class);
            if (in_array($this->report_row, $methods)) {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $return_blank_results is not named in camelCase.
Open

    public function get($return_blank_results=true)
    {
        $template = array();

        if (empty($this->display_rows)) {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $current_page is not named in camelCase.
Open

    public function initialize($load_rows=true)
    {
        $order_set = false;
        $this->table_columns = $this->db->getTableColumns();

Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $group_by is not named in camelCase.
Open

    public function getTotalRows()
    {
        /**
         * if total_column is set, use it to get total rows
         */
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $new_name is not named in camelCase.
Open

    public function joinResult($source_column, $join_table, $join_column, $content_column, $new_name=null, $searchable=false)
    {
        // TODO: this will break if you have more than one db pager at a time
        // TODO: make this a private member variable
        static $join_match = null;
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $new_name is not named in camelCase.
Open

    public function joinResult($source_column, $join_table, $join_column, $content_column, $new_name=null, $searchable=false)
    {
        // TODO: this will break if you have more than one db pager at a time
        // TODO: make this a private member variable
        static $join_match = null;
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $total_pages is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $current_page is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $disp_row is not named in camelCase.
Open

    public function getPageRows()
    {
        $template = null;
        $count = 0;

Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $index_keys is not named in camelCase.
Open

    function createReport()
    {
        if ($this->class) {
            $methods = get_class_methods($this->class);
            if (in_array($this->report_row, $methods)) {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $new_file is not named in camelCase.
Open

    function createReport()
    {
        if ($this->class) {
            $methods = get_class_methods($this->class);
            if (in_array($this->report_row, $methods)) {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $max_tog is not named in camelCase.
Open

    public function get($return_blank_results=true)
    {
        $template = array();

        if (empty($this->display_rows)) {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $full_report is not named in camelCase.
Open

    public function initialize($load_rows=true)
    {
        $order_set = false;
        $this->table_columns = $this->db->getTableColumns();

Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $full_report is not named in camelCase.
Open

    public function initialize($load_rows=true)
    {
        $order_set = false;
        $this->table_columns = $this->db->getTableColumns();

Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $orderby_dir is not named in camelCase.
Open

    public function initialize($load_rows=true)
    {
        $order_set = false;
        $this->table_columns = $this->db->getTableColumns();

Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $col_name is not named in camelCase.
Open

    public function initialize($load_rows=true)
    {
        $order_set = false;
        $this->table_columns = $this->db->getTableColumns();

Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $col_name is not named in camelCase.
Open

    public function initialize($load_rows=true)
    {
        $order_set = false;
        $this->table_columns = $this->db->getTableColumns();

Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $load_rows is not named in camelCase.
Open

    public function initialize($load_rows=true)
    {
        $order_set = false;
        $this->table_columns = $this->db->getTableColumns();

Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $group_by is not named in camelCase.
Open

    public function getTotalRows()
    {
        /**
         * if total_column is set, use it to get total rows
         */
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $source_column is not named in camelCase.
Open

    public function joinResult($source_column, $join_table, $join_column, $content_column, $new_name=null, $searchable=false)
    {
        // TODO: this will break if you have more than one db pager at a time
        // TODO: make this a private member variable
        static $join_match = null;
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $new_name is not named in camelCase.
Open

    public function joinResult($source_column, $join_table, $join_column, $content_column, $new_name=null, $searchable=false)
    {
        // TODO: this will break if you have more than one db pager at a time
        // TODO: make this a private member variable
        static $join_match = null;
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $tbl_idx is not named in camelCase.
Open

    public function joinResult($source_column, $join_table, $join_column, $content_column, $new_name=null, $searchable=false)
    {
        // TODO: this will break if you have more than one db pager at a time
        // TODO: make this a private member variable
        static $join_match = null;
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $total_pages is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $total_pages is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $current_page is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $current_page is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $current_page is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $total_pages is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $current_page is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $back_skip is not named in camelCase.
Open

    public function getPageLinks()
    {
        if ($this->total_pages < 1) {
            $current_page = $total_pages = 1;
        } else {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $disp_row is not named in camelCase.
Open

    public function getPageRows()
    {
        $template = null;
        $count = 0;

Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $disp_row is not named in camelCase.
Open

    public function getPageRows()
    {
        $template = null;
        $count = 0;

Severity: Minor
Found in class/SubselectPager.php by phpmd

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 $func_type is not named in camelCase.
Open

    function createReport()
    {
        if ($this->class) {
            $methods = get_class_methods($this->class);
            if (in_array($this->report_row, $methods)) {
Severity: Minor
Found in class/SubselectPager.php by phpmd

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

There are no issues that match your filters.

Category
Status