mambax7/extgallery

View on GitHub

Showing 9,653 of 9,653 total issues

Avoid variables with short names like $db. Configured minimum length is 3.
Open

    public function __construct(XoopsDatabase $db, $type)
Severity: Minor
Found in class/PhotoHandler.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 $p_file is not named in camelCase.
Open

    function PclErrorFatal($p_file, $p_line, $p_error_string = '')
    {
        global $g_pcl_error_string;
        global $g_pcl_error_code;

Severity: Minor
Found in class/pclerror.lib.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 $p_filelist is not named in camelCase.
Open

    function PclTarCreate($p_tarname, $p_filelist = '', $p_mode = '', $p_add_dir = '', $p_remove_dir = '')
    {
        TrFctStart(__FILE__, __LINE__, 'PclTarCreate', "tar=$p_tarname, file='$p_filelist', mode=$p_mode, add_dir='$p_add_dir', remove_dir='$p_remove_dir'");
        $v_result = 1;

Severity: Minor
Found in class/pcltar.lib.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 $ancestor_id is not named in camelCase.
Open

    public function isDescendantOf($descendant_id, $ancestor_id)
    {
        $node = $this->getNode($ancestor_id);
        if (null === $node) {
            return false;
Severity: Minor
Found in class/NestedTree.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

        while (list($id, $max) = $this->db->fetchRow($result)) {
Severity: Minor
Found in class/PersistableObjectHandler.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 $p_tarname is not named in camelCase.
Open

    function PclTarAdd($p_tarname, $p_filelist)
    {
        TrFctStart(__FILE__, __LINE__, 'PclTarAdd', "tar=$p_tarname, file=$p_filelist");
        $v_result      = 1;
        $v_list_detail = [];
Severity: Minor
Found in class/pcltar.lib.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 $p_filelist is not named in camelCase.
Open

    function PclTarAdd($p_tarname, $p_filelist)
    {
        TrFctStart(__FILE__, __LINE__, 'PclTarAdd', "tar=$p_tarname, file=$p_filelist");
        $v_result      = 1;
        $v_list_detail = [];
Severity: Minor
Found in class/pcltar.lib.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 $p_remove_path is not named in camelCase.
Open

    function PclTarExtract($p_tarname, $p_path = './', $p_remove_path = '', $p_mode = '')
    {
        TrFctStart(__FILE__, __LINE__, 'PclTarExtract', "tar='$p_tarname', path='$p_path', remove_path='$p_remove_path', mode='$p_mode'");
        $v_result = 1;

Severity: Minor
Found in class/pcltar.lib.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 $as_object is not named in camelCase.
Open

    public function convertResultSet($result, $id_as_key = false, $as_object = true)
    {
        $trace = \debug_backtrace(\DEBUG_BACKTRACE_IGNORE_ARGS, 1);
        \trigger_error(__CLASS__ . '::' . __FUNCTION__ . '() is deprecated.' . ". Called from {$trace[0]['file']}line {$trace[0]['line']}", \E_USER_WARNING);
        $ret = [];
Severity: Minor
Found in class/ModelReadIterator.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 $iY. Configured minimum length is 3.
Open

            $iY          = $this->iHeight / 2 + $iCharHeight / 4;
Severity: Minor
Found in class/PhpCaptcha.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 $child_id is not named in camelCase.
Open

    public function isChildOf($child_id, $parent_id)
    {
        $query = \sprintf('SELECT COUNT(*) AS is_child FROM `%s` WHERE `%s` = %d AND %s = %d', $this->table, $this->fields['id'], $child_id, $this->fields['parent'], $parent_id);

        $result = $this->db->query($query);
Severity: Minor
Found in class/NestedTree.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 $p_line is not named in camelCase.
Open

    function PclErrorFatal($p_file, $p_line, $p_error_string = '')
    {
        global $g_pcl_error_string;
        global $g_pcl_error_code;

Severity: Minor
Found in class/pclerror.lib.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 $p_mode is not named in camelCase.
Open

    function PclTarExtract($p_tarname, $p_path = './', $p_remove_path = '', $p_mode = '')
    {
        TrFctStart(__FILE__, __LINE__, 'PclTarExtract', "tar='$p_tarname', path='$p_path', remove_path='$p_remove_path', mode='$p_mode'");
        $v_result = 1;

Severity: Minor
Found in class/pcltar.lib.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

    public function numChildren($id)
Severity: Minor
Found in class/NestedTree.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 $id. Configured minimum length is 3.
Open

    public function deleteById($id, $force = false)
Severity: Minor
Found in class/PersistableObjectHandler.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 $op. Configured minimum length is 3.
Open

    public function updateCounter($fieldname, $criteria, $op = '+')
Severity: Minor
Found in class/PersistableObjectHandler.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 $n. Configured minimum length is 3.
Open

    public function _generateTreeData(&$arr, $id, $level, &$n)
Severity: Minor
Found in class/NestedTree.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 $id. Configured minimum length is 3.
Open

        while (list($id, $sum) = $this->db->fetchRow($result)) {
Severity: Minor
Found in class/PersistableObjectHandler.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 $db. Configured minimum length is 3.
Open

    public function __construct(\XoopsDatabase $db = null)
Severity: Minor
Found in class/QuotaHandler.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 $p_mode is not named in camelCase.
Open

    function PclTarCreate($p_tarname, $p_filelist = '', $p_mode = '', $p_add_dir = '', $p_remove_dir = '')
    {
        TrFctStart(__FILE__, __LINE__, 'PclTarCreate', "tar=$p_tarname, file='$p_filelist', mode=$p_mode, add_dir='$p_add_dir', remove_dir='$p_remove_dir'");
        $v_result = 1;

Severity: Minor
Found in class/pcltar.lib.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

Severity
Category
Status
Source
Language