lib/Ajde/Resource/Image.php

Summary

Maintainability
D
3 days
Test Coverage

File Image.php has 341 lines of code (exceeds 250 allowed). Consider refactoring.
Open

<?php

/*
 * Code from CambioCMS project
 * @link http://code.google.com/p/cambiocms/source/browse/trunk/cms/includes/602_html.image.php
Severity: Minor
Found in lib/Ajde/Resource/Image.php - About 4 hrs to fix

    Ajde_Resource_Image has 29 functions (exceeds 20 allowed). Consider refactoring.
    Open

    class Ajde_Resource_Image extends Ajde_Resource
    {
        protected $_cache;
        protected $_source;
        protected $_type;
    Severity: Minor
    Found in lib/Ajde/Resource/Image.php - About 3 hrs to fix

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

      class Ajde_Resource_Image extends Ajde_Resource
      {
          protected $_cache;
          protected $_source;
          protected $_type;
      Severity: Minor
      Found in lib/Ajde/Resource/Image.php by phpmd

      Method fastimagecopyresampled has 11 arguments (exceeds 4 allowed). Consider refactoring.
      Open

              &$dst_image,
              $src_image,
              $dst_x,
              $dst_y,
              $src_x,
      Severity: Major
      Found in lib/Ajde/Resource/Image.php - About 1 hr to fix

        Method resize has 34 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

            public function resize($height, $width, $crop = true, $xCorrection = 0, $yCorrection = 0)
            {
                if ($this->imageInCache($width, $height, $crop)) {
                    return;
                }
        Severity: Minor
        Found in lib/Ajde/Resource/Image.php - About 1 hr to fix

          Method getGeneratedFilename has 30 lines of code (exceeds 25 allowed). Consider refactoring.
          Open

              public function getGeneratedFilename($width = null, $height = null, $crop = null)
              {
                  if (
                      !isset($width) && !$this->hasWidth() &&
                      !isset($height) && !$this->hasHeight() &&
          Severity: Minor
          Found in lib/Ajde/Resource/Image.php - About 1 hr to fix

            Method fastimagecopyresampled has 29 lines of code (exceeds 25 allowed). Consider refactoring.
            Open

                protected function fastimagecopyresampled(
                    &$dst_image,
                    $src_image,
                    $dst_x,
                    $dst_y,
            Severity: Minor
            Found in lib/Ajde/Resource/Image.php - About 1 hr to fix

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

                  protected function fastimagecopyresampled(
                      &$dst_image,
                      $src_image,
                      $dst_x,
                      $dst_y,
              Severity: Minor
              Found in lib/Ajde/Resource/Image.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 getWidth has a Cognitive Complexity of 9 (exceeds 5 allowed). Consider refactoring.
              Open

                  public function getWidth($calculate = true)
                  {
                      if ($this->has('width') && !$this->isEmpty('width')) {
                          return $this->get('width');
                      } else {
              Severity: Minor
              Found in lib/Ajde/Resource/Image.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

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

                  public function getHeight($calculate = true)
                  {
                      if ($this->has('height') && !$this->isEmpty('height')) {
                          return $this->get('height');
                      } else {
              Severity: Minor
              Found in lib/Ajde/Resource/Image.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

              Function getGeneratedFilename has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring.
              Open

                  public function getGeneratedFilename($width = null, $height = null, $crop = null)
                  {
                      if (
                          !isset($width) && !$this->hasWidth() &&
                          !isset($height) && !$this->hasHeight() &&
              Severity: Minor
              Found in lib/Ajde/Resource/Image.php - About 45 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

              Consider simplifying this complex logical expression.
              Open

                      if (
                          !isset($width) && !$this->hasWidth() &&
                          !isset($height) && !$this->hasHeight() &&
                          !isset($crop) && !$this->hasCrop()
                      ) {
              Severity: Major
              Found in lib/Ajde/Resource/Image.php - About 40 mins to fix

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

                    public function resize($height, $width, $crop = true, $xCorrection = 0, $yCorrection = 0)
                Severity: Minor
                Found in lib/Ajde/Resource/Image.php - About 35 mins to fix

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

                      public function resize($height, $width, $crop = true, $xCorrection = 0, $yCorrection = 0)
                      {
                          if ($this->imageInCache($width, $height, $crop)) {
                              return;
                          }
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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

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

                      public function getImage()
                      {
                          if (isset($this->_cache)) {
                              $image = file_get_contents($this->_cache);
                          } else {
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 fastimagecopyresampled has 11 parameters. Consider reducing the number of parameters to less than 10.
                  Open

                      protected function fastimagecopyresampled(
                          &$dst_image,
                          $src_image,
                          $dst_x,
                          $dst_y,
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.php by phpmd

                  The method getGeneratedFilename() has an NPath complexity of 1008. The configured NPath complexity threshold is 200.
                  Open

                      public function getGeneratedFilename($width = null, $height = null, $crop = null)
                      {
                          if (
                              !isset($width) && !$this->hasWidth() &&
                              !isset($height) && !$this->hasHeight() &&
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 getGeneratedFilename() has a Cyclomatic Complexity of 16. The configured cyclomatic complexity threshold is 10.
                  Open

                      public function getGeneratedFilename($width = null, $height = null, $crop = null)
                      {
                          if (
                              !isset($width) && !$this->hasWidth() &&
                              !isset($height) && !$this->hasHeight() &&
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 fastimagecopyresampled() has a Cyclomatic Complexity of 11. The configured cyclomatic complexity threshold is 10.
                  Open

                      protected function fastimagecopyresampled(
                          &$dst_image,
                          $src_image,
                          $dst_x,
                          $dst_y,
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 '$w' which will lead to PHP notices.
                  Open

                          $image->setWidth($w);
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 '$trnprt_color' which will lead to PHP notices.
                  Open

                                  $transparency = imagecolorallocate($dst_image, $trnprt_color['red'], $trnprt_color['green'],
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 '$trnprt_color' which will lead to PHP notices.
                  Open

                                  $transparency = imagecolorallocate($dst_image, $trnprt_color['red'], $trnprt_color['green'],
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 '$trnprt_color' which will lead to PHP notices.
                  Open

                                      $trnprt_color['blue']);
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 '$s' which will lead to PHP notices.
                  Open

                          $image = new self($s);
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 '$h' which will lead to PHP notices.
                  Open

                          $image->setHeight($h);
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 '$c' which will lead to PHP notices.
                  Open

                          $image->setCrop($c);
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 '$trnprt_indx' which will lead to PHP notices.
                  Open

                                  $transparent_color = imagecolorsforindex($src_image, $trnprt_indx);
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 imageInCache has a boolean flag argument $crop, which is a certain sign of a Single Responsibility Principle violation.
                  Open

                      public function imageInCache($width, $height, $crop = true)
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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

                  Remove error control operator '@' on line 197.
                  Open

                      public function getGeneratedFilename($width = null, $height = null, $crop = null)
                      {
                          if (
                              !isset($width) && !$this->hasWidth() &&
                              !isset($height) && !$this->hasHeight() &&
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.php by phpmd

                  ErrorControlOperator

                  Error suppression should be avoided if possible as it doesn't just suppress the error, that you are trying to stop, but will also suppress errors that you didn't predict would ever occur. Consider changing error_reporting() level and/or setting up your own error handler.

                  Example

                  function foo($filePath) {
                      $file = @fopen($filPath); // hides exceptions
                      $key = @$array[$notExistingKey]; // assigns null to $key
                  }

                  Source http://phpmd.org/rules/cleancode.html#errorcontroloperator

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

                      public function saveCached($width, $height, $crop = true)
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 getWidth has a boolean flag argument $calculate, which is a certain sign of a Single Responsibility Principle violation.
                  Open

                      public function getWidth($calculate = true)
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 resize has a boolean flag argument $crop, which is a certain sign of a Single Responsibility Principle violation.
                  Open

                      public function resize($height, $width, $crop = true, $xCorrection = 0, $yCorrection = 0)
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 getUrl has a boolean flag argument $crop, which is a certain sign of a Single Responsibility Principle violation.
                  Open

                      public function getUrl($width = null, $height = null, $crop = false)
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 getHeight has a boolean flag argument $calculate, which is a certain sign of a Single Responsibility Principle violation.
                  Open

                      public function getHeight($calculate = true)
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 getWidth uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
                  Open

                                  } else {
                                      return $old_x;
                                  }
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 fastimagecopyresampled uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
                  Open

                          } else {
                              imagecopyresampled($dst_image, $src_image, $dst_x, $dst_y, $src_x, $src_y, $dst_w, $dst_h, $src_w, $src_h);
                          }
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 getWidth uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
                  Open

                          } else {
                              if ($calculate === true) {
                                  $old_x = imagesx($this->getImageResource());
                                  if ($this->has('height') && !$this->isEmpty('height')) {
                                      $old_y = imagesy($this->getImageResource());
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 getImage uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
                  Open

                          } else {
                              ob_start();
                              switch ($this->_type) {
                                  case 'jpg':
                                  case 'jpeg':
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 __construct uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
                  Open

                          } else {
                              $this->_source = MEDIA_DIR.'notfound.png';
                          }
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 getHeight uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
                  Open

                                  } else {
                                      return $old_y;
                                  }
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 resize uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
                  Open

                          } else {
                              // Correct for cropping top / bottom
                              $y_offset = $offsetSign * intval(($newHeight - $height) / 2);
                          }
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 getHeight uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
                  Open

                          } else {
                              if ($calculate === true) {
                                  $old_y = imagesy($this->getImageResource());
                                  if ($this->has('width') && !$this->isEmpty('width')) {
                                      $old_x = imagesx($this->getImageResource());
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 assigning values to variables in if clauses and the like (line '148', column '21').
                  Open

                      public function imageInCache($width, $height, $crop = true)
                      {
                          if (is_file($cache = LOCAL_ROOT.$this->getGeneratedFilename($width, $height, $crop))) {
                              $this->_cache = $cache;
                  
                  
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 unused local variables such as '$h'.
                  Open

                          $image->setHeight($h);
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 '$s'.
                  Open

                          $image = new self($s);
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 '$c'.
                  Open

                          $image->setCrop($c);
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 '$trnprt_indx'.
                  Open

                                  $transparent_color = imagecolorsforindex($src_image, $trnprt_indx);
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 '$transparent_color'.
                  Open

                                  $transparent_color = imagecolorsforindex($src_image, $trnprt_indx);
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 '$w'.
                  Open

                          $image->setWidth($w);
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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

                  Similar blocks of code found in 2 locations. Consider refactoring.
                  Open

                      public function getHeight($calculate = true)
                      {
                          if ($this->has('height') && !$this->isEmpty('height')) {
                              return $this->get('height');
                          } else {
                  Severity: Major
                  Found in lib/Ajde/Resource/Image.php and 1 other location - About 3 hrs to fix
                  lib/Ajde/Resource/Image.php on lines 236..254

                  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 145.

                  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

                      public function getWidth($calculate = true)
                      {
                          if ($this->has('width') && !$this->isEmpty('width')) {
                              return $this->get('width');
                          } else {
                  Severity: Major
                  Found in lib/Ajde/Resource/Image.php and 1 other location - About 3 hrs to fix
                  lib/Ajde/Resource/Image.php on lines 216..234

                  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 145.

                  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 property $_source is not named in camelCase.
                  Open

                  class Ajde_Resource_Image extends Ajde_Resource
                  {
                      protected $_cache;
                      protected $_source;
                      protected $_type;
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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

                  The property $_image is not named in camelCase.
                  Open

                  class Ajde_Resource_Image extends Ajde_Resource
                  {
                      protected $_cache;
                      protected $_source;
                      protected $_type;
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $w. Configured minimum length is 3.
                  Open

                          $w = $this->hasWidth() ? $this->getWidth(false) : null;
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 property $_thumbDir is not named in camelCase.
                  Open

                  class Ajde_Resource_Image extends Ajde_Resource
                  {
                      protected $_cache;
                      protected $_source;
                      protected $_type;
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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

                  The parameter $dst_image is not named in camelCase.
                  Open

                      protected function fastimagecopyresampled(
                          &$dst_image,
                          $src_image,
                          $dst_x,
                          $dst_y,
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $src_y is not named in camelCase.
                  Open

                      protected function fastimagecopyresampled(
                          &$dst_image,
                          $src_image,
                          $dst_x,
                          $dst_y,
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $dst_x is not named in camelCase.
                  Open

                      protected function fastimagecopyresampled(
                          &$dst_image,
                          $src_image,
                          $dst_x,
                          $dst_y,
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 class Ajde_Resource_Image is not named in CamelCase.
                  Open

                  class Ajde_Resource_Image extends Ajde_Resource
                  {
                      protected $_cache;
                      protected $_source;
                      protected $_type;
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.php by phpmd

                  CamelCaseClassName

                  Since: 0.2

                  It is considered best practice to use the CamelCase notation to name classes.

                  Example

                  class class_name {
                  }

                  Source

                  The parameter $dst_y is not named in camelCase.
                  Open

                      protected function fastimagecopyresampled(
                          &$dst_image,
                          $src_image,
                          $dst_x,
                          $dst_y,
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $_type is not named in camelCase.
                  Open

                  class Ajde_Resource_Image extends Ajde_Resource
                  {
                      protected $_cache;
                      protected $_source;
                      protected $_type;
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $h. Configured minimum length is 3.
                  Open

                          $h = $this->hasHeight() ? $this->getHeight(false) : null;
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $dst_w is not named in camelCase.
                  Open

                      protected function fastimagecopyresampled(
                          &$dst_image,
                          $src_image,
                          $dst_x,
                          $dst_y,
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $s. Configured minimum length is 3.
                  Open

                          $image = new self($s);
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $src_h is not named in camelCase.
                  Open

                      protected function fastimagecopyresampled(
                          &$dst_image,
                          $src_image,
                          $dst_x,
                          $dst_y,
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $dst_h is not named in camelCase.
                  Open

                      protected function fastimagecopyresampled(
                          &$dst_image,
                          $src_image,
                          $dst_x,
                          $dst_y,
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $_cache is not named in camelCase.
                  Open

                  class Ajde_Resource_Image extends Ajde_Resource
                  {
                      protected $_cache;
                      protected $_source;
                      protected $_type;
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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

                  The parameter $src_image is not named in camelCase.
                  Open

                      protected function fastimagecopyresampled(
                          &$dst_image,
                          $src_image,
                          $dst_x,
                          $dst_y,
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $src_w is not named in camelCase.
                  Open

                      protected function fastimagecopyresampled(
                          &$dst_image,
                          $src_image,
                          $dst_x,
                          $dst_y,
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $src_x is not named in camelCase.
                  Open

                      protected function fastimagecopyresampled(
                          &$dst_image,
                          $src_image,
                          $dst_x,
                          $dst_y,
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 variable $y_offset is not named in camelCase.
                  Open

                      public function resize($height, $width, $crop = true, $xCorrection = 0, $yCorrection = 0)
                      {
                          if ($this->imageInCache($width, $height, $crop)) {
                              return;
                          }
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $x_offset is not named in camelCase.
                  Open

                      public function resize($height, $width, $crop = true, $xCorrection = 0, $yCorrection = 0)
                      {
                          if ($this->imageInCache($width, $height, $crop)) {
                              return;
                          }
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $dst_x is not named in camelCase.
                  Open

                      protected function fastimagecopyresampled(
                          &$dst_image,
                          $src_image,
                          $dst_x,
                          $dst_y,
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $path_info is not named in camelCase.
                  Open

                      protected function filename()
                      {
                          $path_info = pathinfo($this->_source);
                  
                          return $path_info['filename'];
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $src_h is not named in camelCase.
                  Open

                      protected function fastimagecopyresampled(
                          &$dst_image,
                          $src_image,
                          $dst_x,
                          $dst_y,
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $src_w is not named in camelCase.
                  Open

                      protected function fastimagecopyresampled(
                          &$dst_image,
                          $src_image,
                          $dst_x,
                          $dst_y,
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $dst_w is not named in camelCase.
                  Open

                      protected function fastimagecopyresampled(
                          &$dst_image,
                          $src_image,
                          $dst_x,
                          $dst_y,
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $dst_h is not named in camelCase.
                  Open

                      protected function fastimagecopyresampled(
                          &$dst_image,
                          $src_image,
                          $dst_x,
                          $dst_y,
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $dst_w is not named in camelCase.
                  Open

                      protected function fastimagecopyresampled(
                          &$dst_image,
                          $src_image,
                          $dst_x,
                          $dst_y,
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $dst_image is not named in camelCase.
                  Open

                      protected function fastimagecopyresampled(
                          &$dst_image,
                          $src_image,
                          $dst_x,
                          $dst_y,
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $src_x is not named in camelCase.
                  Open

                      protected function fastimagecopyresampled(
                          &$dst_image,
                          $src_image,
                          $dst_x,
                          $dst_y,
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $old_x is not named in camelCase.
                  Open

                      public function getHeight($calculate = true)
                      {
                          if ($this->has('height') && !$this->isEmpty('height')) {
                              return $this->get('height');
                          } else {
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $x_offset is not named in camelCase.
                  Open

                      public function resize($height, $width, $crop = true, $xCorrection = 0, $yCorrection = 0)
                      {
                          if ($this->imageInCache($width, $height, $crop)) {
                              return;
                          }
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $dst_image is not named in camelCase.
                  Open

                      protected function fastimagecopyresampled(
                          &$dst_image,
                          $src_image,
                          $dst_x,
                          $dst_y,
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $old_y is not named in camelCase.
                  Open

                      public function getHeight($calculate = true)
                      {
                          if ($this->has('height') && !$this->isEmpty('height')) {
                              return $this->get('height');
                          } else {
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $path_info is not named in camelCase.
                  Open

                      protected function extension()
                      {
                          $path_info = pathinfo($this->_source);
                  
                          return strtolower(issetor($path_info['extension']));
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $path_info is not named in camelCase.
                  Open

                      protected function dir()
                      {
                          $path_info = pathinfo($this->_source);
                  
                          return $path_info['dirname'];
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $dst_image is not named in camelCase.
                  Open

                      protected function fastimagecopyresampled(
                          &$dst_image,
                          $src_image,
                          $dst_x,
                          $dst_y,
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $dst_y is not named in camelCase.
                  Open

                      protected function fastimagecopyresampled(
                          &$dst_image,
                          $src_image,
                          $dst_x,
                          $dst_y,
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $old_y is not named in camelCase.
                  Open

                      public function getHeight($calculate = true)
                      {
                          if ($this->has('height') && !$this->isEmpty('height')) {
                              return $this->get('height');
                          } else {
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $old_x is not named in camelCase.
                  Open

                      public function getWidth($calculate = true)
                      {
                          if ($this->has('width') && !$this->isEmpty('width')) {
                              return $this->get('width');
                          } else {
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $x_offset is not named in camelCase.
                  Open

                      public function resize($height, $width, $crop = true, $xCorrection = 0, $yCorrection = 0)
                      {
                          if ($this->imageInCache($width, $height, $crop)) {
                              return;
                          }
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $src_image is not named in camelCase.
                  Open

                      protected function fastimagecopyresampled(
                          &$dst_image,
                          $src_image,
                          $dst_x,
                          $dst_y,
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $trnprt_color is not named in camelCase.
                  Open

                      protected function fastimagecopyresampled(
                          &$dst_image,
                          $src_image,
                          $dst_x,
                          $dst_y,
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $dst_h is not named in camelCase.
                  Open

                      protected function fastimagecopyresampled(
                          &$dst_image,
                          $src_image,
                          $dst_x,
                          $dst_y,
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $src_h is not named in camelCase.
                  Open

                      protected function fastimagecopyresampled(
                          &$dst_image,
                          $src_image,
                          $dst_x,
                          $dst_y,
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $old_y is not named in camelCase.
                  Open

                      public function getHeight($calculate = true)
                      {
                          if ($this->has('height') && !$this->isEmpty('height')) {
                              return $this->get('height');
                          } else {
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $old_y is not named in camelCase.
                  Open

                      public function getWidth($calculate = true)
                      {
                          if ($this->has('width') && !$this->isEmpty('width')) {
                              return $this->get('width');
                          } else {
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $dst_image is not named in camelCase.
                  Open

                      protected function fastimagecopyresampled(
                          &$dst_image,
                          $src_image,
                          $dst_x,
                          $dst_y,
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $dst_image is not named in camelCase.
                  Open

                      protected function fastimagecopyresampled(
                          &$dst_image,
                          $src_image,
                          $dst_x,
                          $dst_y,
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $dst_x is not named in camelCase.
                  Open

                      protected function fastimagecopyresampled(
                          &$dst_image,
                          $src_image,
                          $dst_x,
                          $dst_y,
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $path_info is not named in camelCase.
                  Open

                      protected function filename()
                      {
                          $path_info = pathinfo($this->_source);
                  
                          return $path_info['filename'];
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $src_w is not named in camelCase.
                  Open

                      protected function fastimagecopyresampled(
                          &$dst_image,
                          $src_image,
                          $dst_x,
                          $dst_y,
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $old_x is not named in camelCase.
                  Open

                      public function getHeight($calculate = true)
                      {
                          if ($this->has('height') && !$this->isEmpty('height')) {
                              return $this->get('height');
                          } else {
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $y_offset is not named in camelCase.
                  Open

                      public function resize($height, $width, $crop = true, $xCorrection = 0, $yCorrection = 0)
                      {
                          if ($this->imageInCache($width, $height, $crop)) {
                              return;
                          }
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $path_info is not named in camelCase.
                  Open

                      protected function extension()
                      {
                          $path_info = pathinfo($this->_source);
                  
                          return strtolower(issetor($path_info['extension']));
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $dst_image is not named in camelCase.
                  Open

                      protected function fastimagecopyresampled(
                          &$dst_image,
                          $src_image,
                          $dst_x,
                          $dst_y,
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $dst_y is not named in camelCase.
                  Open

                      protected function fastimagecopyresampled(
                          &$dst_image,
                          $src_image,
                          $dst_x,
                          $dst_y,
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $src_image is not named in camelCase.
                  Open

                      protected function fastimagecopyresampled(
                          &$dst_image,
                          $src_image,
                          $dst_x,
                          $dst_y,
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $dst_w is not named in camelCase.
                  Open

                      protected function fastimagecopyresampled(
                          &$dst_image,
                          $src_image,
                          $dst_x,
                          $dst_y,
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $y_offset is not named in camelCase.
                  Open

                      public function resize($height, $width, $crop = true, $xCorrection = 0, $yCorrection = 0)
                      {
                          if ($this->imageInCache($width, $height, $crop)) {
                              return;
                          }
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $src_image is not named in camelCase.
                  Open

                      protected function fastimagecopyresampled(
                          &$dst_image,
                          $src_image,
                          $dst_x,
                          $dst_y,
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $trnprt_indx is not named in camelCase.
                  Open

                      protected function fastimagecopyresampled(
                          &$dst_image,
                          $src_image,
                          $dst_x,
                          $dst_y,
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $trnprt_color is not named in camelCase.
                  Open

                      protected function fastimagecopyresampled(
                          &$dst_image,
                          $src_image,
                          $dst_x,
                          $dst_y,
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $dst_image is not named in camelCase.
                  Open

                      protected function fastimagecopyresampled(
                          &$dst_image,
                          $src_image,
                          $dst_x,
                          $dst_y,
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $src_h is not named in camelCase.
                  Open

                      protected function fastimagecopyresampled(
                          &$dst_image,
                          $src_image,
                          $dst_x,
                          $dst_y,
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $src_image is not named in camelCase.
                  Open

                      protected function fastimagecopyresampled(
                          &$dst_image,
                          $src_image,
                          $dst_x,
                          $dst_y,
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $dst_h is not named in camelCase.
                  Open

                      protected function fastimagecopyresampled(
                          &$dst_image,
                          $src_image,
                          $dst_x,
                          $dst_y,
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $path_info is not named in camelCase.
                  Open

                      protected function dir()
                      {
                          $path_info = pathinfo($this->_source);
                  
                          return $path_info['dirname'];
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $src_image is not named in camelCase.
                  Open

                      protected function fastimagecopyresampled(
                          &$dst_image,
                          $src_image,
                          $dst_x,
                          $dst_y,
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $transparent_color is not named in camelCase.
                  Open

                      protected function fastimagecopyresampled(
                          &$dst_image,
                          $src_image,
                          $dst_x,
                          $dst_y,
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $trnprt_color is not named in camelCase.
                  Open

                      protected function fastimagecopyresampled(
                          &$dst_image,
                          $src_image,
                          $dst_x,
                          $dst_y,
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $src_x is not named in camelCase.
                  Open

                      protected function fastimagecopyresampled(
                          &$dst_image,
                          $src_image,
                          $dst_x,
                          $dst_y,
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $dst_image is not named in camelCase.
                  Open

                      protected function fastimagecopyresampled(
                          &$dst_image,
                          $src_image,
                          $dst_x,
                          $dst_y,
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $dst_h is not named in camelCase.
                  Open

                      protected function fastimagecopyresampled(
                          &$dst_image,
                          $src_image,
                          $dst_x,
                          $dst_y,
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $dst_image is not named in camelCase.
                  Open

                      protected function fastimagecopyresampled(
                          &$dst_image,
                          $src_image,
                          $dst_x,
                          $dst_y,
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $dst_image is not named in camelCase.
                  Open

                      protected function fastimagecopyresampled(
                          &$dst_image,
                          $src_image,
                          $dst_x,
                          $dst_y,
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $dst_w is not named in camelCase.
                  Open

                      protected function fastimagecopyresampled(
                          &$dst_image,
                          $src_image,
                          $dst_x,
                          $dst_y,
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $dst_h is not named in camelCase.
                  Open

                      protected function fastimagecopyresampled(
                          &$dst_image,
                          $src_image,
                          $dst_x,
                          $dst_y,
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $src_y is not named in camelCase.
                  Open

                      protected function fastimagecopyresampled(
                          &$dst_image,
                          $src_image,
                          $dst_x,
                          $dst_y,
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $src_w is not named in camelCase.
                  Open

                      protected function fastimagecopyresampled(
                          &$dst_image,
                          $src_image,
                          $dst_x,
                          $dst_y,
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $old_x is not named in camelCase.
                  Open

                      public function getWidth($calculate = true)
                      {
                          if ($this->has('width') && !$this->isEmpty('width')) {
                              return $this->get('width');
                          } else {
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $dst_w is not named in camelCase.
                  Open

                      protected function fastimagecopyresampled(
                          &$dst_image,
                          $src_image,
                          $dst_x,
                          $dst_y,
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $dst_h is not named in camelCase.
                  Open

                      protected function fastimagecopyresampled(
                          &$dst_image,
                          $src_image,
                          $dst_x,
                          $dst_y,
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $old_x is not named in camelCase.
                  Open

                      public function getWidth($calculate = true)
                      {
                          if ($this->has('width') && !$this->isEmpty('width')) {
                              return $this->get('width');
                          } else {
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $dst_w is not named in camelCase.
                  Open

                      protected function fastimagecopyresampled(
                          &$dst_image,
                          $src_image,
                          $dst_x,
                          $dst_y,
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $src_y is not named in camelCase.
                  Open

                      protected function fastimagecopyresampled(
                          &$dst_image,
                          $src_image,
                          $dst_x,
                          $dst_y,
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $x_offset is not named in camelCase.
                  Open

                      public function resize($height, $width, $crop = true, $xCorrection = 0, $yCorrection = 0)
                      {
                          if ($this->imageInCache($width, $height, $crop)) {
                              return;
                          }
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $y_offset is not named in camelCase.
                  Open

                      public function resize($height, $width, $crop = true, $xCorrection = 0, $yCorrection = 0)
                      {
                          if ($this->imageInCache($width, $height, $crop)) {
                              return;
                          }
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $old_y is not named in camelCase.
                  Open

                      public function getWidth($calculate = true)
                      {
                          if ($this->has('width') && !$this->isEmpty('width')) {
                              return $this->get('width');
                          } else {
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $x_offset is not named in camelCase.
                  Open

                      public function resize($height, $width, $crop = true, $xCorrection = 0, $yCorrection = 0)
                      {
                          if ($this->imageInCache($width, $height, $crop)) {
                              return;
                          }
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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 $y_offset is not named in camelCase.
                  Open

                      public function resize($height, $width, $crop = true, $xCorrection = 0, $yCorrection = 0)
                      {
                          if ($this->imageInCache($width, $height, $crop)) {
                              return;
                          }
                  Severity: Minor
                  Found in lib/Ajde/Resource/Image.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