lancew/DojoList

View on GitHub

Showing 1,940 of 1,940 total issues

The parameter $path_or_array is not named in camelCase.
Open

function dispatch_patch($path_or_array, $callback, $options = array())
{
  route("PATCH", $path_or_array, $callback, $options);
}
Severity: Minor
Found in lib/limonade.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 $p. Configured minimum length is 3.
Open

    $p = explode('/',$param);
Severity: Minor
Found in lib/limonade.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 $fh. Configured minimum length is 3.
Open

    $fh = fopen($file, 'w') or die("can't open file");
Severity: Minor
Found in lib/rss.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 $output_as_html is not named in camelCase.
Open

function debug($var, $output_as_html = true)
{ 
  if ( is_null($var) ) { return '<span class="null-value">[NULL]</span>'; };
  $out = '';
  switch ($var) 
Severity: Minor
Found in lib/limonade.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 $path_or_array is not named in camelCase.
Open

function dispatch_delete($path_or_array, $callback, $options = array())
{
  route("DELETE", $path_or_array, $callback, $options);
}
Severity: Minor
Found in lib/limonade.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 $max_items is not named in camelCase.
Open

function Delete_Oldest_rss($max_items='20')
{
    $new_rss = RSS_header();
    $item_count = 0;
    $rss = Load_RSS_data();
Severity: Minor
Found in lib/rss.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 $path_or_array is not named in camelCase.
Open

function dispatch_post($path_or_array, $callback, $options = array())
{
  route("POST", $path_or_array, $callback, $options);
}
Severity: Minor
Found in lib/limonade.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 $post_data is not named in camelCase.
Open

function test_request($url, $method="GET", $include_header=false, $post_data=array(), $http_header=array()) {
    $method = strtoupper($method);
    $allowed_methods = array("GET", "PUT", "POST", "DELETE", "HEAD");
    if(!in_array($method, $allowed_methods))
    {
Severity: Minor
Found in lib/limonade/tests.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 $fs. Configured minimum length is 3.
Open

    if(false == ( $fs = @fsockopen($host, $port, $errno, $errstr, 10) ) ) {
Severity: Minor
Found in lib/recaptchalib.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 $name_or_array_or_null is not named in camelCase.
Open

function params($name_or_array_or_null = null, $value = null)
{
  static $params = array();
  $args = func_get_args();

Severity: Minor
Found in lib/limonade.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 property $is_valid is not named in camelCase.
Open

class ReCaptchaResponse
{
        var $is_valid;
        var $error;
}
Severity: Minor
Found in lib/recaptchalib.php by phpmd

CamelCasePropertyName

Since: 0.2

It is considered best practice to use the camelCase notation to name attributes.

Example

class ClassName {
    protected $property_name;
}

Source

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

function request_method_is_allowed($m = null)
Severity: Minor
Found in lib/limonade.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 $prevents_output is not named in camelCase.
Open

function require_once_dir($path, $pattern = "*.php", $prevents_output = true)
{
  if($path[strlen($path) - 1] != "/") $path .= "/";
  $filenames = glob($path.$pattern);
  if(!is_array($filenames)) $filenames = array();
Severity: Minor
Found in lib/limonade.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 $path_or_array is not named in camelCase.
Open

function dispatch_put($path_or_array, $callback, $options = array())
{
  route("PUT", $path_or_array, $callback, $options);
}
Severity: Minor
Found in lib/limonade.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 $a. Configured minimum length is 3.
Open

          $a = array_fill(0, $n_names - $n_matches, null);
Severity: Minor
Found in lib/limonade.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 $k. Configured minimum length is 3.
Open

            list($k, $v) = explode('=', $param);
Severity: Minor
Found in lib/limonade.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 $path_or_array is not named in camelCase.
Open

function dispatch($path_or_array, $callback, $options = array())
{
  dispatch_get($path_or_array, $callback, $options);
}
Severity: Minor
Found in lib/limonade.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 $function_or_file is not named in camelCase.
Open

function layout($function_or_file = null)
{
  static $layout = null;
  if(func_num_args() > 0) $layout = $function_or_file;
  return $layout;
Severity: Minor
Found in lib/limonade.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 $quote_style is not named in camelCase.
Open

function limonade_htmlspecialchars_decode($string, $quote_style = ENT_COMPAT)
{
    $table = array_flip(get_html_translation_table(HTML_SPECIALCHARS, $quote_style));
    if($quote_style === ENT_QUOTES)
        $table['&#039;'] = $table['&#39;'] = '\'';
Severity: Minor
Found in lib/limonade.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 $r. Configured minimum length is 3.
Open

  $r = http_response_status($num);
Severity: Minor
Found in lib/limonade.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

Severity
Category
Status
Source
Language