mambax7/adslight

View on GitHub
modify.php

Summary

Maintainability
F
5 days
Test Coverage

modifyAd accesses the super-global variable $GLOBALS.
Open

function modifyAd($lid): void
{
    global $xoopsDB, $xoopsModule, $xoopsConfig, $myts;
    $contactselect = '';
    require_once XOOPS_ROOT_PATH . '/class/xoopsformloader.php';
Severity: Minor
Found in modify.php by phpmd

Superglobals

Since: 0.2

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

Example

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

Source

modifyAds accesses the super-global variable $GLOBALS.
Open

function modifyAds(
    $lid,
    $cat,
    $title,
    $status,
Severity: Minor
Found in modify.php by phpmd

Superglobals

Since: 0.2

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

Example

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

Source

modifyAd accesses the super-global variable $GLOBALS.
Open

function modifyAd($lid): void
{
    global $xoopsDB, $xoopsModule, $xoopsConfig, $myts;
    $contactselect = '';
    require_once XOOPS_ROOT_PATH . '/class/xoopsformloader.php';
Severity: Minor
Found in modify.php by phpmd

Superglobals

Since: 0.2

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

Example

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

Source

modifyAd accesses the super-global variable $GLOBALS.
Open

function modifyAd($lid): void
{
    global $xoopsDB, $xoopsModule, $xoopsConfig, $myts;
    $contactselect = '';
    require_once XOOPS_ROOT_PATH . '/class/xoopsformloader.php';
Severity: Minor
Found in modify.php by phpmd

Superglobals

Since: 0.2

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

Example

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

Source

modifyAd accesses the super-global variable $GLOBALS.
Open

function modifyAd($lid): void
{
    global $xoopsDB, $xoopsModule, $xoopsConfig, $myts;
    $contactselect = '';
    require_once XOOPS_ROOT_PATH . '/class/xoopsformloader.php';
Severity: Minor
Found in modify.php by phpmd

Superglobals

Since: 0.2

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

Example

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

Source

modifyAd accesses the super-global variable $GLOBALS.
Open

function modifyAd($lid): void
{
    global $xoopsDB, $xoopsModule, $xoopsConfig, $myts;
    $contactselect = '';
    require_once XOOPS_ROOT_PATH . '/class/xoopsformloader.php';
Severity: Minor
Found in modify.php by phpmd

Superglobals

Since: 0.2

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

Example

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

Source

modifyAd accesses the super-global variable $GLOBALS.
Open

function modifyAd($lid): void
{
    global $xoopsDB, $xoopsModule, $xoopsConfig, $myts;
    $contactselect = '';
    require_once XOOPS_ROOT_PATH . '/class/xoopsformloader.php';
Severity: Minor
Found in modify.php by phpmd

Superglobals

Since: 0.2

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

Example

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

Source

listingDel accesses the super-global variable $GLOBALS.
Open

function listingDel($lid, $ok): void
{
    global $xoopsDB;
    $helper = Helper::getInstance();
    $sql = 'SELECT usid FROM ' . $xoopsDB->prefix('adslight_listing') . ' WHERE lid=' . $xoopsDB->escape($lid);
Severity: Minor
Found in modify.php by phpmd

Superglobals

Since: 0.2

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

Example

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

Source

modifyAd accesses the super-global variable $GLOBALS.
Open

function modifyAd($lid): void
{
    global $xoopsDB, $xoopsModule, $xoopsConfig, $myts;
    $contactselect = '';
    require_once XOOPS_ROOT_PATH . '/class/xoopsformloader.php';
Severity: Minor
Found in modify.php by phpmd

Superglobals

Since: 0.2

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

Example

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

Source

modifyAd accesses the super-global variable $GLOBALS.
Open

function modifyAd($lid): void
{
    global $xoopsDB, $xoopsModule, $xoopsConfig, $myts;
    $contactselect = '';
    require_once XOOPS_ROOT_PATH . '/class/xoopsformloader.php';
Severity: Minor
Found in modify.php by phpmd

Superglobals

Since: 0.2

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

Example

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

Source

delReply accesses the super-global variable $GLOBALS.
Open

function delReply($r_lid, $ok): void
{
    global $xoopsDB;
    $helper = Helper::getInstance();
    $sql    = 'SELECT l.usid, r.r_lid, r.lid, r.title, r.date_created, r.submitter, r.message, r.tele, r.email, r.r_usid FROM ' . $xoopsDB->prefix(
Severity: Minor
Found in modify.php by phpmd

Superglobals

Since: 0.2

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

Example

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

Source

modifyAd accesses the super-global variable $GLOBALS.
Open

function modifyAd($lid): void
{
    global $xoopsDB, $xoopsModule, $xoopsConfig, $myts;
    $contactselect = '';
    require_once XOOPS_ROOT_PATH . '/class/xoopsformloader.php';
Severity: Minor
Found in modify.php by phpmd

Superglobals

Since: 0.2

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

Example

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

Source

modifyAd accesses the super-global variable $GLOBALS.
Open

function modifyAd($lid): void
{
    global $xoopsDB, $xoopsModule, $xoopsConfig, $myts;
    $contactselect = '';
    require_once XOOPS_ROOT_PATH . '/class/xoopsformloader.php';
Severity: Minor
Found in modify.php by phpmd

Superglobals

Since: 0.2

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

Example

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

Source

listingDel accesses the super-global variable $GLOBALS.
Open

function listingDel($lid, $ok): void
{
    global $xoopsDB;
    $helper = Helper::getInstance();
    $sql = 'SELECT usid FROM ' . $xoopsDB->prefix('adslight_listing') . ' WHERE lid=' . $xoopsDB->escape($lid);
Severity: Minor
Found in modify.php by phpmd

Superglobals

Since: 0.2

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

Example

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

Source

delReply accesses the super-global variable $GLOBALS.
Open

function delReply($r_lid, $ok): void
{
    global $xoopsDB;
    $helper = Helper::getInstance();
    $sql    = 'SELECT l.usid, r.r_lid, r.lid, r.title, r.date_created, r.submitter, r.message, r.tele, r.email, r.r_usid FROM ' . $xoopsDB->prefix(
Severity: Minor
Found in modify.php by phpmd

Superglobals

Since: 0.2

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

Example

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

Source

modifyAd accesses the super-global variable $GLOBALS.
Open

function modifyAd($lid): void
{
    global $xoopsDB, $xoopsModule, $xoopsConfig, $myts;
    $contactselect = '';
    require_once XOOPS_ROOT_PATH . '/class/xoopsformloader.php';
Severity: Minor
Found in modify.php by phpmd

Superglobals

Since: 0.2

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

Example

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

Source

modifyAds accesses the super-global variable $GLOBALS.
Open

function modifyAds(
    $lid,
    $cat,
    $title,
    $status,
Severity: Minor
Found in modify.php by phpmd

Superglobals

Since: 0.2

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

Example

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

Source

Function modifyAd has a Cognitive Complexity of 88 (exceeds 5 allowed). Consider refactoring.
Open

function modifyAd($lid): void
{
    global $xoopsDB, $xoopsModule, $xoopsConfig, $myts;
    $contactselect = '';
    require_once XOOPS_ROOT_PATH . '/class/xoopsformloader.php';
Severity: Minor
Found in modify.php - About 1 day to fix

Cognitive Complexity

Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

A method's cognitive complexity is based on a few simple rules:

  • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
  • Code is considered more complex for each "break in the linear flow of the code"
  • Code is considered more complex when "flow breaking structures are nested"

Further reading

Method modifyAd has 223 lines of code (exceeds 25 allowed). Consider refactoring.
Open

function modifyAd($lid): void
{
    global $xoopsDB, $xoopsModule, $xoopsConfig, $myts;
    $contactselect = '';
    require_once XOOPS_ROOT_PATH . '/class/xoopsformloader.php';
Severity: Major
Found in modify.php - About 1 day to fix

    File modify.php has 441 lines of code (exceeds 250 allowed). Consider refactoring.
    Open

    <?php declare(strict_types=1);
    
    /*
     * You may not change or alter any portion of this comment or credits
     * of supporting developers from this source code or any supporting source code
    Severity: Minor
    Found in modify.php - About 6 hrs to fix

      Function listingDel has a Cognitive Complexity of 36 (exceeds 5 allowed). Consider refactoring.
      Open

      function listingDel($lid, $ok): void
      {
          global $xoopsDB;
          $helper = Helper::getInstance();
          $sql = 'SELECT usid FROM ' . $xoopsDB->prefix('adslight_listing') . ' WHERE lid=' . $xoopsDB->escape($lid);
      Severity: Minor
      Found in modify.php - About 5 hrs to fix

      Cognitive Complexity

      Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

      A method's cognitive complexity is based on a few simple rules:

      • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
      • Code is considered more complex for each "break in the linear flow of the code"
      • Code is considered more complex when "flow breaking structures are nested"

      Further reading

      Method modifyAds has 19 arguments (exceeds 4 allowed). Consider refactoring.
      Open

          $lid,
          $cat,
          $title,
          $status,
          $expire,
      Severity: Major
      Found in modify.php - About 2 hrs to fix

        Method listingDel has 51 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

        function listingDel($lid, $ok): void
        {
            global $xoopsDB;
            $helper = Helper::getInstance();
            $sql = 'SELECT usid FROM ' . $xoopsDB->prefix('adslight_listing') . ' WHERE lid=' . $xoopsDB->escape($lid);
        Severity: Major
        Found in modify.php - About 2 hrs to fix

          Method delReply has 35 lines of code (exceeds 25 allowed). Consider refactoring.
          Open

          function delReply($r_lid, $ok): void
          {
              global $xoopsDB;
              $helper = Helper::getInstance();
              $sql    = 'SELECT l.usid, r.r_lid, r.lid, r.title, r.date_created, r.submitter, r.message, r.tele, r.email, r.r_usid FROM ' . $xoopsDB->prefix(
          Severity: Minor
          Found in modify.php - About 1 hr to fix

            Avoid deeply nested control flow statements.
            Open

                                    if (is_file("{$destination}/{$purl}")) {
                                        unlink("{$destination}/{$purl}");
                                    }
            Severity: Major
            Found in modify.php - About 45 mins to fix

              Avoid deeply nested control flow statements.
              Open

                                      if (is_file("{$destination2}/thumb_{$purl}")) {
                                          unlink("{$destination2}/thumb_{$purl}");
                                      }
              Severity: Major
              Found in modify.php - About 45 mins to fix

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

                function delReply($r_lid, $ok): void
                {
                    global $xoopsDB;
                    $helper = Helper::getInstance();
                    $sql    = 'SELECT l.usid, r.r_lid, r.lid, r.title, r.date_created, r.submitter, r.message, r.tele, r.email, r.r_usid FROM ' . $xoopsDB->prefix(
                Severity: Minor
                Found in modify.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

                Avoid deeply nested control flow statements.
                Open

                                        if (is_file("{$destination3}/resized_{$purl}")) {
                                            unlink("{$destination3}/resized_{$purl}");
                                        }
                Severity: Major
                Found in modify.php - About 45 mins to fix

                  The function modifyAd() has an NPath complexity of 127402000. The configured NPath complexity threshold is 200.
                  Open

                  function modifyAd($lid): void
                  {
                      global $xoopsDB, $xoopsModule, $xoopsConfig, $myts;
                      $contactselect = '';
                      require_once XOOPS_ROOT_PATH . '/class/xoopsformloader.php';
                  Severity: Minor
                  Found in modify.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 function modifyAds has 19 parameters. Consider reducing the number of parameters to less than 10.
                  Open

                  function modifyAds(
                      $lid,
                      $cat,
                      $title,
                      $status,
                  Severity: Minor
                  Found in modify.php by phpmd

                  The function modifyAd() has 257 lines of code. Current threshold is set to 100. Avoid really long methods.
                  Open

                  function modifyAd($lid): void
                  {
                      global $xoopsDB, $xoopsModule, $xoopsConfig, $myts;
                      $contactselect = '';
                      require_once XOOPS_ROOT_PATH . '/class/xoopsformloader.php';
                  Severity: Minor
                  Found in modify.php by phpmd

                  The function listingDel() has a Cyclomatic Complexity of 11. The configured cyclomatic complexity threshold is 10.
                  Open

                  function listingDel($lid, $ok): void
                  {
                      global $xoopsDB;
                      $helper = Helper::getInstance();
                      $sql = 'SELECT usid FROM ' . $xoopsDB->prefix('adslight_listing') . ' WHERE lid=' . $xoopsDB->escape($lid);
                  Severity: Minor
                  Found in modify.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 function modifyAd() has a Cyclomatic Complexity of 33. The configured cyclomatic complexity threshold is 10.
                  Open

                  function modifyAd($lid): void
                  {
                      global $xoopsDB, $xoopsModule, $xoopsConfig, $myts;
                      $contactselect = '';
                      require_once XOOPS_ROOT_PATH . '/class/xoopsformloader.php';
                  Severity: Minor
                  Found in modify.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

                  Missing class import via use statement (line '203', column '35').
                  Open

                              $tempXoopsLocal = new \XoopsLocal();
                  Severity: Minor
                  Found in modify.php by phpmd

                  MissingImport

                  Since: 2.7.0

                  Importing all external classes in a file through use statements makes them clearly visible.

                  Example

                  function make() {
                      return new \stdClass();
                  }

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

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

                              } else {
                                  echo "<tr>
                      <td width='30%' class='head'>" . _ADSLIGHT_WILL_LAST . " </td><td class='head'>{$expire}  " . _ADSLIGHT_DAY . '</td>
                      </tr>';
                                  echo "<input type=\"hidden\" name=\"expire\" value=\"{$expire}\" >";
                  Severity: Minor
                  Found in modify.php by phpmd

                  ElseExpression

                  Since: 1.4.0

                  An if expression with an else branch is basically not necessary. You can rewrite the conditions in a way that the else clause is not necessary and the code becomes simpler to read. To achieve this, use early return statements, though you may need to split the code it several smaller methods. For very simple assignments you could also use the ternary operations.

                  Example

                  class Foo
                  {
                      public function bar($flag)
                      {
                          if ($flag) {
                              // one branch
                          } else {
                              // another branch
                          }
                      }
                  }

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

                  Avoid using static access to class '\XoopsModules\Adslight\Helper' in method 'listingDel'.
                  Open

                      $helper = Helper::getInstance();
                  Severity: Minor
                  Found in modify.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

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

                  Avoid using static access to class '\XoopsModules\Adslight\Helper' in method 'delReply'.
                  Open

                      $helper = Helper::getInstance();
                  Severity: Minor
                  Found in modify.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

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

                  Avoid using static access to class '\XoopsModules\Adslight\Utility' in method 'modifyAd'.
                  Open

                      $categories = Utility::getMyItemIds('adslight_submit');
                  Severity: Minor
                  Found in modify.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

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

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

                              } else {
                                  echo '<tr><td class="head">' . _ADSLIGHT_EMAIL . " </td><td class=\"head\">{$email}<input type=\"hidden\" name=\"email\" value=\"{$email}\" ></td>";
                              }
                  Severity: Minor
                  Found in modify.php by phpmd

                  ElseExpression

                  Since: 1.4.0

                  An if expression with an else branch is basically not necessary. You can rewrite the conditions in a way that the else clause is not necessary and the code becomes simpler to read. To achieve this, use early return statements, though you may need to split the code it several smaller methods. For very simple assignments you could also use the ternary operations.

                  Example

                  class Foo
                  {
                      public function bar($flag)
                      {
                          if ($flag) {
                              // one branch
                          } else {
                              // another branch
                          }
                      }
                  }

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

                  Avoid using static access to class '\Xmf\Request' in method 'modifyAd'.
                  Open

                              $perm_itemid      = Request::getInt('item_id', 0, 'POST');
                  Severity: Minor
                  Found in modify.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

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

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

                              } else {
                                  echo '<td class="head">' . _ADSLIGHT_SENDBY . " </td><td class=\"head\"><input type=\"hidden\" name=\"submitter\" value=\"{$submitter}\">{$submitter}</td>";
                              }
                  Severity: Minor
                  Found in modify.php by phpmd

                  ElseExpression

                  Since: 1.4.0

                  An if expression with an else branch is basically not necessary. You can rewrite the conditions in a way that the else clause is not necessary and the code becomes simpler to read. To achieve this, use early return statements, though you may need to split the code it several smaller methods. For very simple assignments you could also use the ternary operations.

                  Example

                  class Foo
                  {
                      public function bar($flag)
                      {
                          if ($flag) {
                              // one branch
                          } else {
                              // another branch
                          }
                      }
                  }

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

                  Avoid using static access to class '\XoopsModules\Adslight\Helper' in method 'modifyAds'.
                  Open

                      $helper = Helper::getInstance();
                  Severity: Minor
                  Found in modify.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

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

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

                              } else {
                                  echo "<table width='100%' border='0' cellspacing='1' cellpadding='8'><tr class='bg4'><td valign='top'>\n";
                                  echo '<br><div style="text-align:center">';
                                  echo '<strong>' . _ADSLIGHT_SURDELANN . '</strong></div><br><br>';
                              }
                  Severity: Minor
                  Found in modify.php by phpmd

                  ElseExpression

                  Since: 1.4.0

                  An if expression with an else branch is basically not necessary. You can rewrite the conditions in a way that the else clause is not necessary and the code becomes simpler to read. To achieve this, use early return statements, though you may need to split the code it several smaller methods. For very simple assignments you could also use the ternary operations.

                  Example

                  class Foo
                  {
                      public function bar($flag)
                      {
                          if ($flag) {
                              // one branch
                          } else {
                              // another branch
                          }
                      }
                  }

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

                  Avoid using static access to class '\XoopsModules\Adslight\Helper' in method 'modifyAd'.
                  Open

                      $helper            = Helper::getInstance();
                  Severity: Minor
                  Found in modify.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

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

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

                              } else {
                                  echo '<input type="hidden" name="valid" value="Yes" >';
                              }
                  Severity: Minor
                  Found in modify.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 modifyAd uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
                  Open

                      } else {    // User can't see any category
                          redirect_header(XOOPS_URL . '/index.php', 3, _NOPERM);
                      }
                  Severity: Minor
                  Found in modify.php by phpmd

                  ElseExpression

                  Since: 1.4.0

                  An if expression with an else branch is basically not necessary. You can rewrite the conditions in a way that the else clause is not necessary and the code becomes simpler to read. To achieve this, use early return statements, though you may need to split the code it several smaller methods. For very simple assignments you could also use the ternary operations.

                  Example

                  class Foo
                  {
                      public function bar($flag)
                      {
                          if ($flag) {
                              // one branch
                          } else {
                              // another branch
                          }
                      }
                  }

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

                  Avoid using static access to class '\Xmf\Request' in method 'modifyAd'.
                  Open

                              $perm_itemid      = Request::getInt('item_id', 0, 'GET');
                  Severity: Minor
                  Found in modify.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

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

                  Avoid using static access to class '\XoopsModules\Adslight\Utility' in method 'modifyAd'.
                  Open

                              $wysiwyg_text_area = Utility::getEditor($helper, $options);
                  Severity: Minor
                  Found in modify.php by phpmd

                  StaticAccess

                  Since: 1.4.0

                  Static access causes unexchangeable dependencies to other classes and leads to hard to test code. Avoid using static access at all costs and instead inject dependencies through the constructor. The only case when static access is acceptable is when used for factory methods.

                  Example

                  class Foo
                  {
                      public function bar()
                      {
                          Bar::baz();
                      }
                  }

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

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

                              } else {
                                  echo "<table width='100%' border='0' cellspacing='1' cellpadding='8'><tr class='bg4'><td valign='top'>\n";
                                  echo '<br><div style="text-align:center">';
                                  echo '<strong>' . _ADSLIGHT_SURDELANN . '</strong></div><br><br>';
                              }
                  Severity: Minor
                  Found in modify.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 modifyAd uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
                  Open

                              } else {
                                  echo '<input type="hidden" name="country" value="">';
                              }
                  Severity: Minor
                  Found in modify.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 modifyAd uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
                  Open

                              } else {
                                  $groups = XOOPS_GROUP_ANONYMOUS;
                              }
                  Severity: Minor
                  Found in modify.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 unused local variables such as '$title'.
                  Open

                      [$usid, $r_lid, $rlid, $title, $date_created, $submitter, $message, $tele, $email, $r_usid] = $xoopsDB->fetchRow(
                  Severity: Minor
                  Found in modify.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 '$useroffset'.
                  Open

                              $useroffset    = '';
                  Severity: Minor
                  Found in modify.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 '$result'.
                  Open

                      $result = $xoopsDB->query($sql);
                  Severity: Minor
                  Found in modify.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 '$rlid'.
                  Open

                      [$usid, $r_lid, $rlid, $title, $date_created, $submitter, $message, $tele, $email, $r_usid] = $xoopsDB->fetchRow(
                  Severity: Minor
                  Found in modify.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 '$email'.
                  Open

                      [$usid, $r_lid, $rlid, $title, $date_created, $submitter, $message, $tele, $email, $r_usid] = $xoopsDB->fetchRow(
                  Severity: Minor
                  Found in modify.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 parameters such as '$date_created'.
                  Open

                      $date_created,
                  Severity: Minor
                  Found in modify.php by phpmd

                  UnusedFormalParameter

                  Since: 0.2

                  Avoid passing parameters to methods or constructors and then not using those parameters.

                  Example

                  class Foo
                  {
                      private function bar($howdy)
                      {
                          // $howdy is not used
                      }
                  }

                  Source https://phpmd.org/rules/unusedcode.html#unusedformalparameter

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

                      [$usid, $r_lid, $rlid, $title, $date_created, $submitter, $message, $tele, $email, $r_usid] = $xoopsDB->fetchRow(
                  Severity: Minor
                  Found in modify.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 '$message'.
                  Open

                      [$usid, $r_lid, $rlid, $title, $date_created, $submitter, $message, $tele, $email, $r_usid] = $xoopsDB->fetchRow(
                  Severity: Minor
                  Found in modify.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 '$date_created'.
                  Open

                      [$usid, $r_lid, $rlid, $title, $date_created, $submitter, $message, $tele, $email, $r_usid] = $xoopsDB->fetchRow(
                  Severity: Minor
                  Found in modify.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 '$myts'.
                  Open

                      global $xoopsDB, $myts;
                  Severity: Minor
                  Found in modify.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 '$submitter'.
                  Open

                      [$usid, $r_lid, $rlid, $title, $date_created, $submitter, $message, $tele, $email, $r_usid] = $xoopsDB->fetchRow(
                  Severity: Minor
                  Found in modify.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 '$valid'.
                  Open

                      [$lid, $cide, $title, $status, $expire, $type, $desctext, $tel, $price, $typeprice, $typecondition, $date_created, $email, $submitter, $usid, $town, $country, $contactby, $premium, $valid] = $xoopsDB->fetchRow(
                  Severity: Minor
                  Found in modify.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 '$tele'.
                  Open

                      [$usid, $r_lid, $rlid, $title, $date_created, $submitter, $message, $tele, $email, $r_usid] = $xoopsDB->fetchRow(
                  Severity: Minor
                  Found in modify.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 variables with short names like $ok. Configured minimum length is 3.
                  Open

                  function delReply($r_lid, $ok): void
                  Severity: Minor
                  Found in modify.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 $date_created is not named in camelCase.
                  Open

                  function modifyAds(
                      $lid,
                      $cat,
                      $title,
                      $status,
                  Severity: Minor
                  Found in modify.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 $ok. Configured minimum length is 3.
                  Open

                  function listingDel($lid, $ok): void
                  Severity: Minor
                  Found in modify.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 $r_lid is not named in camelCase.
                  Open

                  function delReply($r_lid, $ok): void
                  {
                      global $xoopsDB;
                      $helper = Helper::getInstance();
                      $sql    = 'SELECT l.usid, r.r_lid, r.lid, r.title, r.date_created, r.submitter, r.message, r.tele, r.email, r.r_usid FROM ' . $xoopsDB->prefix(
                  Severity: Minor
                  Found in modify.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

                  A file should declare new symbols (classes, functions, constants, etc.) and cause no other side effects, or it should execute logic with side effects, but should not do both. The first symbol is defined on line 51 and the first side effect is on line 31.
                  Open

                  <?php declare(strict_types=1);
                  Severity: Minor
                  Found in modify.php by phpcodesniffer

                  There must be one USE keyword per declaration
                  Open

                  use XoopsModules\Adslight\{
                  Severity: Minor
                  Found in modify.php by phpcodesniffer

                  Line exceeds 120 characters; contains 122 characters
                  Open

                              //            $wysiwyg_text_area = Utility::getEditor(_ADSLIGHT_DESC, 'desctext', $desctext, '100%', '200px');
                  Severity: Minor
                  Found in modify.php by phpcodesniffer

                  Line exceeds 120 characters; contains 166 characters
                  Open

                                  echo '<tr><td class="head">' . _ADSLIGHT_EMAIL . " </td><td class=\"head\"><input type=\"text\" name=\"email\" size=\"50\" value=\"{$email}\" ></td>";
                  Severity: Minor
                  Found in modify.php by phpcodesniffer

                  Line exceeds 120 characters; contains 208 characters
                  Open

                              echo '<tr><td class="head">' . _ADSLIGHT_PRICE2 . " </td><td class=\"head\"><input type=\"text\" name=\"price\" size=\"20\" value=\"{$price}\" > " . $helper->getConfig('adslight_currency_symbol');
                  Severity: Minor
                  Found in modify.php by phpcodesniffer

                  Line exceeds 120 characters; contains 122 characters
                  Open

                                  echo "<table width='100%' border='0' cellspacing='1' cellpadding='8'><tr class='bg4'><td valign='top'>\n";
                  Severity: Minor
                  Found in modify.php by phpcodesniffer

                  Line exceeds 120 characters; contains 195 characters
                  Open

                      <td width='30%' class='head'>" . _ADSLIGHT_HOW_LONG . " </td><td class='head'><input type=\"text\" name=\"expire\" size=\"3\" maxlength=\"3\" value=\"{$expire}\" >  " . _ADSLIGHT_DAY . '</td>
                  Severity: Minor
                  Found in modify.php by phpcodesniffer

                  Line exceeds 120 characters; contains 214 characters
                  Open

                      [$lid, $cide, $title, $status, $expire, $type, $desctext, $tel, $price, $typeprice, $typecondition, $date_created, $email, $submitter, $usid, $town, $country, $contactby, $premium, $valid] = $xoopsDB->fetchRow(
                  Severity: Minor
                  Found in modify.php by phpcodesniffer

                  Line exceeds 120 characters; contains 135 characters
                  Open

                              $sql     = 'SELECT nom_condition, id_condition FROM ' . $xoopsDB->prefix('adslight_condition') . ' ORDER BY nom_condition';
                  Severity: Minor
                  Found in modify.php by phpcodesniffer

                  Line exceeds 120 characters; contains 125 characters
                  Open

                      <td class="head">' . _ADSLIGHT_NUMANNN . " </td><td class=\"head\" border=\"1\">{$lid} " . _ADSLIGHT_DU . " {$dates}</td>
                  Severity: Minor
                  Found in modify.php by phpcodesniffer

                  Line exceeds 120 characters; contains 253 characters
                  Open

                      echo "<script language=\"javascript\">\nfunction CLA(CLA) { var MainWindow = window.open (CLA, \"_blank\",\"width=500,height=300,toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=yes,resizable=yes,copyhistory=no\");}\n</script>";
                  Severity: Minor
                  Found in modify.php by phpcodesniffer

                  Line exceeds 120 characters; contains 143 characters
                  Open

                      <td class="head">' . _ADSLIGHT_TITLE2 . " </td><td class=\"head\"><input type=\"text\" name=\"title\" size=\"50\" value=\"{$title}\" ></td>
                  Severity: Minor
                  Found in modify.php by phpcodesniffer

                  Line exceeds 120 characters; contains 121 characters
                  Open

                              echo "<fieldset><legend style='font-weight: bold; color: #900;'>" . _ADSLIGHT_MODIFANN . '</legend><br><br>';
                  Severity: Minor
                  Found in modify.php by phpcodesniffer

                  Line exceeds 120 characters; contains 164 characters
                  Open

                                  echo '<tr><td class="head">' . _ADSLIGHT_EMAIL . " </td><td class=\"head\">{$email}<input type=\"hidden\" name=\"email\" value=\"{$email}\" ></td>";
                  Severity: Minor
                  Found in modify.php by phpcodesniffer

                  Line exceeds 120 characters; contains 139 characters
                  Open

                      <td class="head">' . _ADSLIGHT_TOWN . " </td><td class=\"head\"><input type=\"text\" name=\"town\" size=\"50\" value=\"{$town}\" ></td>
                  Severity: Minor
                  Found in modify.php by phpcodesniffer

                  Line exceeds 120 characters; contains 136 characters
                  Open

                              echo "<tr><td class='head'>" . _ADSLIGHT_STATUS . "</td><td class='head'><input type=\"radio\" name=\"status\" value=\"0\"";
                  Severity: Minor
                  Found in modify.php by phpcodesniffer

                  Line exceeds 120 characters; contains 129 characters
                  Open

                              $groups   = $GLOBALS['xoopsUser'] instanceof \XoopsUser ? $GLOBALS['xoopsUser']->getGroups() : XOOPS_GROUP_ANONYMOUS;
                  Severity: Minor
                  Found in modify.php by phpcodesniffer

                  Line exceeds 120 characters; contains 171 characters
                  Open

                                  echo '<td class="head">' . _ADSLIGHT_SENDBY . " </td><td class=\"head\"><input type=\"text\" name=\"submitter\" size=\"50\" value=\"{$submitter}\" ></td>";
                  Severity: Minor
                  Found in modify.php by phpcodesniffer

                  Line exceeds 120 characters; contains 172 characters
                  Open

                                  echo '<td class="head">' . _ADSLIGHT_SENDBY . " </td><td class=\"head\"><input type=\"hidden\" name=\"submitter\" value=\"{$submitter}\">{$submitter}</td>";
                  Severity: Minor
                  Found in modify.php by phpcodesniffer

                  Line exceeds 120 characters; contains 392 characters
                  Open

                                . " SET cid='{$cat}', title='{$title}', status='{$status}',  expire='{$expire}', type='{$type}', desctext='{$desctext}', tel='{$tel}', price='{$price}', typeprice='{$typeprice}', typecondition='{$typecondition}', email='{$email}', submitter='{$submitter}', town='{$town}', country='{$country}', contactby='{$contactby}', premium='{$premium}', valid='{$valid}' WHERE lid={$lid}";
                  Severity: Minor
                  Found in modify.php by phpcodesniffer

                  Line exceeds 120 characters; contains 136 characters
                  Open

                      <td class="head">' . _ADSLIGHT_TEL . " </td><td class=\"head\"><input type=\"text\" name=\"tel\" size=\"50\" value=\"{$tel}\" ></td>
                  Severity: Minor
                  Found in modify.php by phpcodesniffer

                  Line exceeds 120 characters; contains 122 characters
                  Open

                                  echo "<table width='100%' border='0' cellspacing='1' cellpadding='8'><tr class='bg4'><td valign='top'>\n";
                  Severity: Minor
                  Found in modify.php by phpcodesniffer

                  Line exceeds 120 characters; contains 214 characters
                  Open

                      $sql    = 'SELECT lid, cid, title, status, expire, type, desctext, tel, price, typeprice, typecondition, date_created, email, submitter, usid, town, country, contactby, premium, valid FROM ' . $xoopsDB->prefix(
                  Severity: Minor
                  Found in modify.php by phpcodesniffer

                  Line exceeds 120 characters; contains 151 characters
                  Open

                              echo '[ <a href="modify.php?op=ListingDel&amp;lid=' . $lid . '&amp;ok=1">' . _YES . '</a> | <a href="index.php">' . _NO . '</a> ]<br><br>';
                  Severity: Minor
                  Found in modify.php by phpcodesniffer

                  Line exceeds 120 characters; contains 148 characters
                  Open

                      <td class="head">' . _ADSLIGHT_COUNTRY . " </td><td class=\"head\"><input type=\"text\" name=\"country\" size=\"50\" value=\"{$country}\" ></td>
                  Severity: Minor
                  Found in modify.php by phpcodesniffer

                  Line exceeds 120 characters; contains 147 characters
                  Open

                      $sql    = 'SELECT l.usid, r.r_lid, r.lid, r.title, r.date_created, r.submitter, r.message, r.tele, r.email, r.r_usid FROM ' . $xoopsDB->prefix(
                  Severity: Minor
                  Found in modify.php by phpcodesniffer

                  Multi-line function call not indented correctly; expected 16 spaces but found 20
                  Open

                                      $r_lid
                  Severity: Minor
                  Found in modify.php by phpcodesniffer

                  Multi-line function call not indented correctly; expected 20 spaces but found 21
                  Open

                                       $usid
                  Severity: Minor
                  Found in modify.php by phpcodesniffer

                  Multi-line function call not indented correctly; expected 4 spaces but found 8
                  Open

                          ) . ' l LEFT JOIN ' . $xoopsDB->prefix(
                  Severity: Minor
                  Found in modify.php by phpcodesniffer

                  Multi-line function call not indented correctly; expected 8 spaces but found 12
                  Open

                              'adslight_listing'
                  Severity: Minor
                  Found in modify.php by phpcodesniffer

                  Multi-line function call not indented correctly; expected 16 spaces but found 17
                  Open

                                   ) . '">' . _NO . '</a> ]<br><br>';
                  Severity: Minor
                  Found in modify.php by phpcodesniffer

                  Multi-line function call not indented correctly; expected 4 spaces but found 8
                  Open

                          ) . ' WHERE lid=' . $xoopsDB->escape(
                  Severity: Minor
                  Found in modify.php by phpcodesniffer

                  Multi-line function call not indented correctly; expected 8 spaces but found 12
                  Open

                              'adslight_listing'
                  Severity: Minor
                  Found in modify.php by phpcodesniffer

                  Multi-line function call not indented correctly; expected 12 spaces but found 16
                  Open

                                  ) . '&amp;ok=1">' . _YES . '</a> | <a href="members.php?usid=' . addslashes(
                  Severity: Minor
                  Found in modify.php by phpcodesniffer

                  The variable $perm_itemid is not named in camelCase.
                  Open

                  function modifyAd($lid): void
                  {
                      global $xoopsDB, $xoopsModule, $xoopsConfig, $myts;
                      $contactselect = '';
                      require_once XOOPS_ROOT_PATH . '/class/xoopsformloader.php';
                  Severity: Minor
                  Found in modify.php by phpmd

                  CamelCaseVariableName

                  Since: 0.2

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

                  Example

                  class ClassName {
                      public function doSomething() {
                          $data_module = new DataModule();
                      }
                  }

                  Source

                  The variable $id_type is not named in camelCase.
                  Open

                  function modifyAd($lid): void
                  {
                      global $xoopsDB, $xoopsModule, $xoopsConfig, $myts;
                      $contactselect = '';
                      require_once XOOPS_ROOT_PATH . '/class/xoopsformloader.php';
                  Severity: Minor
                  Found in modify.php by phpmd

                  CamelCaseVariableName

                  Since: 0.2

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

                  Example

                  class ClassName {
                      public function doSomething() {
                          $data_module = new DataModule();
                      }
                  }

                  Source

                  The variable $r_lid is not named in camelCase.
                  Open

                  function delReply($r_lid, $ok): void
                  {
                      global $xoopsDB;
                      $helper = Helper::getInstance();
                      $sql    = 'SELECT l.usid, r.r_lid, r.lid, r.title, r.date_created, r.submitter, r.message, r.tele, r.email, r.r_usid FROM ' . $xoopsDB->prefix(
                  Severity: Minor
                  Found in modify.php by phpmd

                  CamelCaseVariableName

                  Since: 0.2

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

                  Example

                  class ClassName {
                      public function doSomething() {
                          $data_module = new DataModule();
                      }
                  }

                  Source

                  The variable $nom_price is not named in camelCase.
                  Open

                  function modifyAd($lid): void
                  {
                      global $xoopsDB, $xoopsModule, $xoopsConfig, $myts;
                      $contactselect = '';
                      require_once XOOPS_ROOT_PATH . '/class/xoopsformloader.php';
                  Severity: Minor
                  Found in modify.php by phpmd

                  CamelCaseVariableName

                  Since: 0.2

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

                  Example

                  class ClassName {
                      public function doSomething() {
                          $data_module = new DataModule();
                      }
                  }

                  Source

                  The variable $nom_type is not named in camelCase.
                  Open

                  function modifyAd($lid): void
                  {
                      global $xoopsDB, $xoopsModule, $xoopsConfig, $myts;
                      $contactselect = '';
                      require_once XOOPS_ROOT_PATH . '/class/xoopsformloader.php';
                  Severity: Minor
                  Found in modify.php by phpmd

                  CamelCaseVariableName

                  Since: 0.2

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

                  Example

                  class ClassName {
                      public function doSomething() {
                          $data_module = new DataModule();
                      }
                  }

                  Source

                  The variable $nom_type is not named in camelCase.
                  Open

                  function modifyAd($lid): void
                  {
                      global $xoopsDB, $xoopsModule, $xoopsConfig, $myts;
                      $contactselect = '';
                      require_once XOOPS_ROOT_PATH . '/class/xoopsformloader.php';
                  Severity: Minor
                  Found in modify.php by phpmd

                  CamelCaseVariableName

                  Since: 0.2

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

                  Example

                  class ClassName {
                      public function doSomething() {
                          $data_module = new DataModule();
                      }
                  }

                  Source

                  The variable $r_usid is not named in camelCase.
                  Open

                  function delReply($r_lid, $ok): void
                  {
                      global $xoopsDB;
                      $helper = Helper::getInstance();
                      $sql    = 'SELECT l.usid, r.r_lid, r.lid, r.title, r.date_created, r.submitter, r.message, r.tele, r.email, r.r_usid FROM ' . $xoopsDB->prefix(
                  Severity: Minor
                  Found in modify.php by phpmd

                  CamelCaseVariableName

                  Since: 0.2

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

                  Example

                  class ClassName {
                      public function doSomething() {
                          $data_module = new DataModule();
                      }
                  }

                  Source

                  The variable $id_type is not named in camelCase.
                  Open

                  function modifyAd($lid): void
                  {
                      global $xoopsDB, $xoopsModule, $xoopsConfig, $myts;
                      $contactselect = '';
                      require_once XOOPS_ROOT_PATH . '/class/xoopsformloader.php';
                  Severity: Minor
                  Found in modify.php by phpmd

                  CamelCaseVariableName

                  Since: 0.2

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

                  Example

                  class ClassName {
                      public function doSomething() {
                          $data_module = new DataModule();
                      }
                  }

                  Source

                  The variable $wysiwyg_text_area is not named in camelCase.
                  Open

                  function modifyAd($lid): void
                  {
                      global $xoopsDB, $xoopsModule, $xoopsConfig, $myts;
                      $contactselect = '';
                      require_once XOOPS_ROOT_PATH . '/class/xoopsformloader.php';
                  Severity: Minor
                  Found in modify.php by phpmd

                  CamelCaseVariableName

                  Since: 0.2

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

                  Example

                  class ClassName {
                      public function doSomething() {
                          $data_module = new DataModule();
                      }
                  }

                  Source

                  The variable $perm_itemid is not named in camelCase.
                  Open

                  function modifyAd($lid): void
                  {
                      global $xoopsDB, $xoopsModule, $xoopsConfig, $myts;
                      $contactselect = '';
                      require_once XOOPS_ROOT_PATH . '/class/xoopsformloader.php';
                  Severity: Minor
                  Found in modify.php by phpmd

                  CamelCaseVariableName

                  Since: 0.2

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

                  Example

                  class ClassName {
                      public function doSomething() {
                          $data_module = new DataModule();
                      }
                  }

                  Source

                  The variable $date_created is not named in camelCase.
                  Open

                  function modifyAd($lid): void
                  {
                      global $xoopsDB, $xoopsModule, $xoopsConfig, $myts;
                      $contactselect = '';
                      require_once XOOPS_ROOT_PATH . '/class/xoopsformloader.php';
                  Severity: Minor
                  Found in modify.php by phpmd

                  CamelCaseVariableName

                  Since: 0.2

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

                  Example

                  class ClassName {
                      public function doSomething() {
                          $data_module = new DataModule();
                      }
                  }

                  Source

                  The variable $perm_itemid is not named in camelCase.
                  Open

                  function modifyAd($lid): void
                  {
                      global $xoopsDB, $xoopsModule, $xoopsConfig, $myts;
                      $contactselect = '';
                      require_once XOOPS_ROOT_PATH . '/class/xoopsformloader.php';
                  Severity: Minor
                  Found in modify.php by phpmd

                  CamelCaseVariableName

                  Since: 0.2

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

                  Example

                  class ClassName {
                      public function doSomething() {
                          $data_module = new DataModule();
                      }
                  }

                  Source

                  The variable $date_created is not named in camelCase.
                  Open

                  function modifyAd($lid): void
                  {
                      global $xoopsDB, $xoopsModule, $xoopsConfig, $myts;
                      $contactselect = '';
                      require_once XOOPS_ROOT_PATH . '/class/xoopsformloader.php';
                  Severity: Minor
                  Found in modify.php by phpmd

                  CamelCaseVariableName

                  Since: 0.2

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

                  Example

                  class ClassName {
                      public function doSomething() {
                          $data_module = new DataModule();
                      }
                  }

                  Source

                  The variable $id_price is not named in camelCase.
                  Open

                  function modifyAd($lid): void
                  {
                      global $xoopsDB, $xoopsModule, $xoopsConfig, $myts;
                      $contactselect = '';
                      require_once XOOPS_ROOT_PATH . '/class/xoopsformloader.php';
                  Severity: Minor
                  Found in modify.php by phpmd

                  CamelCaseVariableName

                  Since: 0.2

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

                  Example

                  class ClassName {
                      public function doSomething() {
                          $data_module = new DataModule();
                      }
                  }

                  Source

                  The variable $nom_condition is not named in camelCase.
                  Open

                  function modifyAd($lid): void
                  {
                      global $xoopsDB, $xoopsModule, $xoopsConfig, $myts;
                      $contactselect = '';
                      require_once XOOPS_ROOT_PATH . '/class/xoopsformloader.php';
                  Severity: Minor
                  Found in modify.php by phpmd

                  CamelCaseVariableName

                  Since: 0.2

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

                  Example

                  class ClassName {
                      public function doSomething() {
                          $data_module = new DataModule();
                      }
                  }

                  Source

                  The variable $id_type is not named in camelCase.
                  Open

                  function modifyAd($lid): void
                  {
                      global $xoopsDB, $xoopsModule, $xoopsConfig, $myts;
                      $contactselect = '';
                      require_once XOOPS_ROOT_PATH . '/class/xoopsformloader.php';
                  Severity: Minor
                  Found in modify.php by phpmd

                  CamelCaseVariableName

                  Since: 0.2

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

                  Example

                  class ClassName {
                      public function doSomething() {
                          $data_module = new DataModule();
                      }
                  }

                  Source

                  The variable $r_lid is not named in camelCase.
                  Open

                  function delReply($r_lid, $ok): void
                  {
                      global $xoopsDB;
                      $helper = Helper::getInstance();
                      $sql    = 'SELECT l.usid, r.r_lid, r.lid, r.title, r.date_created, r.submitter, r.message, r.tele, r.email, r.r_usid FROM ' . $xoopsDB->prefix(
                  Severity: Minor
                  Found in modify.php by phpmd

                  CamelCaseVariableName

                  Since: 0.2

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

                  Example

                  class ClassName {
                      public function doSomething() {
                          $data_module = new DataModule();
                      }
                  }

                  Source

                  The variable $r_lid is not named in camelCase.
                  Open

                  function delReply($r_lid, $ok): void
                  {
                      global $xoopsDB;
                      $helper = Helper::getInstance();
                      $sql    = 'SELECT l.usid, r.r_lid, r.lid, r.title, r.date_created, r.submitter, r.message, r.tele, r.email, r.r_usid FROM ' . $xoopsDB->prefix(
                  Severity: Minor
                  Found in modify.php by phpmd

                  CamelCaseVariableName

                  Since: 0.2

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

                  Example

                  class ClassName {
                      public function doSomething() {
                          $data_module = new DataModule();
                      }
                  }

                  Source

                  The variable $id_price is not named in camelCase.
                  Open

                  function modifyAd($lid): void
                  {
                      global $xoopsDB, $xoopsModule, $xoopsConfig, $myts;
                      $contactselect = '';
                      require_once XOOPS_ROOT_PATH . '/class/xoopsformloader.php';
                  Severity: Minor
                  Found in modify.php by phpmd

                  CamelCaseVariableName

                  Since: 0.2

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

                  Example

                  class ClassName {
                      public function doSomething() {
                          $data_module = new DataModule();
                      }
                  }

                  Source

                  The variable $date_created is not named in camelCase.
                  Open

                  function modifyAd($lid): void
                  {
                      global $xoopsDB, $xoopsModule, $xoopsConfig, $myts;
                      $contactselect = '';
                      require_once XOOPS_ROOT_PATH . '/class/xoopsformloader.php';
                  Severity: Minor
                  Found in modify.php by phpmd

                  CamelCaseVariableName

                  Since: 0.2

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

                  Example

                  class ClassName {
                      public function doSomething() {
                          $data_module = new DataModule();
                      }
                  }

                  Source

                  The variable $nom_price is not named in camelCase.
                  Open

                  function modifyAd($lid): void
                  {
                      global $xoopsDB, $xoopsModule, $xoopsConfig, $myts;
                      $contactselect = '';
                      require_once XOOPS_ROOT_PATH . '/class/xoopsformloader.php';
                  Severity: Minor
                  Found in modify.php by phpmd

                  CamelCaseVariableName

                  Since: 0.2

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

                  Example

                  class ClassName {
                      public function doSomething() {
                          $data_module = new DataModule();
                      }
                  }

                  Source

                  The variable $wysiwyg_text_area is not named in camelCase.
                  Open

                  function modifyAd($lid): void
                  {
                      global $xoopsDB, $xoopsModule, $xoopsConfig, $myts;
                      $contactselect = '';
                      require_once XOOPS_ROOT_PATH . '/class/xoopsformloader.php';
                  Severity: Minor
                  Found in modify.php by phpmd

                  CamelCaseVariableName

                  Since: 0.2

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

                  Example

                  class ClassName {
                      public function doSomething() {
                          $data_module = new DataModule();
                      }
                  }

                  Source

                  The variable $id_price is not named in camelCase.
                  Open

                  function modifyAd($lid): void
                  {
                      global $xoopsDB, $xoopsModule, $xoopsConfig, $myts;
                      $contactselect = '';
                      require_once XOOPS_ROOT_PATH . '/class/xoopsformloader.php';
                  Severity: Minor
                  Found in modify.php by phpmd

                  CamelCaseVariableName

                  Since: 0.2

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

                  Example

                  class ClassName {
                      public function doSomething() {
                          $data_module = new DataModule();
                      }
                  }

                  Source

                  The variable $nom_condition is not named in camelCase.
                  Open

                  function modifyAd($lid): void
                  {
                      global $xoopsDB, $xoopsModule, $xoopsConfig, $myts;
                      $contactselect = '';
                      require_once XOOPS_ROOT_PATH . '/class/xoopsformloader.php';
                  Severity: Minor
                  Found in modify.php by phpmd

                  CamelCaseVariableName

                  Since: 0.2

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

                  Example

                  class ClassName {
                      public function doSomething() {
                          $data_module = new DataModule();
                      }
                  }

                  Source

                  The variable $date_created is not named in camelCase.
                  Open

                  function delReply($r_lid, $ok): void
                  {
                      global $xoopsDB;
                      $helper = Helper::getInstance();
                      $sql    = 'SELECT l.usid, r.r_lid, r.lid, r.title, r.date_created, r.submitter, r.message, r.tele, r.email, r.r_usid FROM ' . $xoopsDB->prefix(
                  Severity: Minor
                  Found in modify.php by phpmd

                  CamelCaseVariableName

                  Since: 0.2

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

                  Example

                  class ClassName {
                      public function doSomething() {
                          $data_module = new DataModule();
                      }
                  }

                  Source

                  The variable $id_condition is not named in camelCase.
                  Open

                  function modifyAd($lid): void
                  {
                      global $xoopsDB, $xoopsModule, $xoopsConfig, $myts;
                      $contactselect = '';
                      require_once XOOPS_ROOT_PATH . '/class/xoopsformloader.php';
                  Severity: Minor
                  Found in modify.php by phpmd

                  CamelCaseVariableName

                  Since: 0.2

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

                  Example

                  class ClassName {
                      public function doSomething() {
                          $data_module = new DataModule();
                      }
                  }

                  Source

                  The variable $id_condition is not named in camelCase.
                  Open

                  function modifyAd($lid): void
                  {
                      global $xoopsDB, $xoopsModule, $xoopsConfig, $myts;
                      $contactselect = '';
                      require_once XOOPS_ROOT_PATH . '/class/xoopsformloader.php';
                  Severity: Minor
                  Found in modify.php by phpmd

                  CamelCaseVariableName

                  Since: 0.2

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

                  Example

                  class ClassName {
                      public function doSomething() {
                          $data_module = new DataModule();
                      }
                  }

                  Source

                  The variable $r_lid is not named in camelCase.
                  Open

                  function delReply($r_lid, $ok): void
                  {
                      global $xoopsDB;
                      $helper = Helper::getInstance();
                      $sql    = 'SELECT l.usid, r.r_lid, r.lid, r.title, r.date_created, r.submitter, r.message, r.tele, r.email, r.r_usid FROM ' . $xoopsDB->prefix(
                  Severity: Minor
                  Found in modify.php by phpmd

                  CamelCaseVariableName

                  Since: 0.2

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

                  Example

                  class ClassName {
                      public function doSomething() {
                          $data_module = new DataModule();
                      }
                  }

                  Source

                  The variable $id_condition is not named in camelCase.
                  Open

                  function modifyAd($lid): void
                  {
                      global $xoopsDB, $xoopsModule, $xoopsConfig, $myts;
                      $contactselect = '';
                      require_once XOOPS_ROOT_PATH . '/class/xoopsformloader.php';
                  Severity: Minor
                  Found in modify.php by phpmd

                  CamelCaseVariableName

                  Since: 0.2

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

                  Example

                  class ClassName {
                      public function doSomething() {
                          $data_module = new DataModule();
                      }
                  }

                  Source

                  The variable $perm_itemid is not named in camelCase.
                  Open

                  function modifyAd($lid): void
                  {
                      global $xoopsDB, $xoopsModule, $xoopsConfig, $myts;
                      $contactselect = '';
                      require_once XOOPS_ROOT_PATH . '/class/xoopsformloader.php';
                  Severity: Minor
                  Found in modify.php by phpmd

                  CamelCaseVariableName

                  Since: 0.2

                  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