APO-Epsilon/apo-website

View on GitHub
leader_list.php

Summary

Maintainability
D
1 day
Test Coverage

show_active accesses the super-global variable $_GET.
Open

function show_active() {
    echo "<h1>Events you are leading:</h1>";

    $user_id = $_SESSION['sessionID'];
       include('mysql_access.php');
Severity: Minor
Found in leader_list.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

show_active accesses the super-global variable $_GET.
Open

function show_active() {
    echo "<h1>Events you are leading:</h1>";

    $user_id = $_SESSION['sessionID'];
       include('mysql_access.php');
Severity: Minor
Found in leader_list.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

show_active accesses the super-global variable $_SESSION.
Open

function show_active() {
    echo "<h1>Events you are leading:</h1>";

    $user_id = $_SESSION['sessionID'];
       include('mysql_access.php');
Severity: Minor
Found in leader_list.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

show_active accesses the super-global variable $_GET.
Open

function show_active() {
    echo "<h1>Events you are leading:</h1>";

    $user_id = $_SESSION['sessionID'];
       include('mysql_access.php');
Severity: Minor
Found in leader_list.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

show_active accesses the super-global variable $_GET.
Open

function show_active() {
    echo "<h1>Events you are leading:</h1>";

    $user_id = $_SESSION['sessionID'];
       include('mysql_access.php');
Severity: Minor
Found in leader_list.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

show_active accesses the super-global variable $_GET.
Open

function show_active() {
    echo "<h1>Events you are leading:</h1>";

    $user_id = $_SESSION['sessionID'];
       include('mysql_access.php');
Severity: Minor
Found in leader_list.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

show_active accesses the super-global variable $_GET.
Open

function show_active() {
    echo "<h1>Events you are leading:</h1>";

    $user_id = $_SESSION['sessionID'];
       include('mysql_access.php');
Severity: Minor
Found in leader_list.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

submit_event accesses the super-global variable $_SESSION.
Open

function submit_event($entry) {
  include ('mysql_access.php');
  $user_id = $_SESSION['sessionID'];

        $wresponse=$db->query("SELECT week_cd FROM week LIMIT 1");
Severity: Minor
Found in leader_list.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

show_active accesses the super-global variable $_GET.
Open

function show_active() {
    echo "<h1>Events you are leading:</h1>";

    $user_id = $_SESSION['sessionID'];
       include('mysql_access.php');
Severity: Minor
Found in leader_list.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

show_active accesses the super-global variable $_GET.
Open

function show_active() {
    echo "<h1>Events you are leading:</h1>";

    $user_id = $_SESSION['sessionID'];
       include('mysql_access.php');
Severity: Minor
Found in leader_list.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

show_active accesses the super-global variable $_GET.
Open

function show_active() {
    echo "<h1>Events you are leading:</h1>";

    $user_id = $_SESSION['sessionID'];
       include('mysql_access.php');
Severity: Minor
Found in leader_list.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

show_active accesses the super-global variable $_GET.
Open

function show_active() {
    echo "<h1>Events you are leading:</h1>";

    $user_id = $_SESSION['sessionID'];
       include('mysql_access.php');
Severity: Minor
Found in leader_list.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

show_active accesses the super-global variable $_GET.
Open

function show_active() {
    echo "<h1>Events you are leading:</h1>";

    $user_id = $_SESSION['sessionID'];
       include('mysql_access.php');
Severity: Minor
Found in leader_list.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

show_active accesses the super-global variable $_GET.
Open

function show_active() {
    echo "<h1>Events you are leading:</h1>";

    $user_id = $_SESSION['sessionID'];
       include('mysql_access.php');
Severity: Minor
Found in leader_list.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

show_active accesses the super-global variable $_GET.
Open

function show_active() {
    echo "<h1>Events you are leading:</h1>";

    $user_id = $_SESSION['sessionID'];
       include('mysql_access.php');
Severity: Minor
Found in leader_list.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

show_active accesses the super-global variable $_GET.
Open

function show_active() {
    echo "<h1>Events you are leading:</h1>";

    $user_id = $_SESSION['sessionID'];
       include('mysql_access.php');
Severity: Minor
Found in leader_list.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 show_active has a Cognitive Complexity of 54 (exceeds 5 allowed). Consider refactoring.
Open

function show_active() {
    echo "<h1>Events you are leading:</h1>";

    $user_id = $_SESSION['sessionID'];
       include('mysql_access.php');
Severity: Minor
Found in leader_list.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 show_active has 104 lines of code (exceeds 25 allowed). Consider refactoring.
Open

function show_active() {
    echo "<h1>Events you are leading:</h1>";

    $user_id = $_SESSION['sessionID'];
       include('mysql_access.php');
Severity: Major
Found in leader_list.php - About 4 hrs to fix

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

    function submit_event($entry) {
      include ('mysql_access.php');
      $user_id = $_SESSION['sessionID'];
    
            $wresponse=$db->query("SELECT week_cd FROM week LIMIT 1");
    Severity: Minor
    Found in leader_list.php - About 1 hr to fix

      The function show_active() has an NPath complexity of 208. The configured NPath complexity threshold is 200.
      Open

      function show_active() {
          echo "<h1>Events you are leading:</h1>";
      
          $user_id = $_SESSION['sessionID'];
             include('mysql_access.php');
      Severity: Minor
      Found in leader_list.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 show_active() has 118 lines of code. Current threshold is set to 100. Avoid really long methods.
      Open

      function show_active() {
          echo "<h1>Events you are leading:</h1>";
      
          $user_id = $_SESSION['sessionID'];
             include('mysql_access.php');
      Severity: Minor
      Found in leader_list.php by phpmd

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

      function show_active() {
          echo "<h1>Events you are leading:</h1>";
      
          $user_id = $_SESSION['sessionID'];
             include('mysql_access.php');
      Severity: Minor
      Found in leader_list.php by phpmd

      CyclomaticComplexity

      Since: 0.1

      Complexity is determined by the number of decision points in a method plus one for the method entry. The decision points are 'if', 'while', 'for', and 'case labels'. Generally, 1-4 is low complexity, 5-7 indicates moderate complexity, 8-10 is high complexity, and 11+ is very high complexity.

      Example

      // Cyclomatic Complexity = 11
      class Foo {
      1   public function example() {
      2       if ($a == $b) {
      3           if ($a1 == $b1) {
                      fiddle();
      4           } elseif ($a2 == $b2) {
                      fiddle();
                  } else {
                      fiddle();
                  }
      5       } elseif ($c == $d) {
      6           while ($c == $d) {
                      fiddle();
                  }
      7        } elseif ($e == $f) {
      8           for ($n = 0; $n < $h; $n++) {
                      fiddle();
                  }
              } else {
                  switch ($z) {
      9               case 1:
                          fiddle();
                          break;
      10              case 2:
                          fiddle();
                          break;
      11              case 3:
                          fiddle();
                          break;
                      default:
                          fiddle();
                          break;
                  }
              }
          }
      }

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

      Avoid using undefined variables such as '$db' which will lead to PHP notices.
      Open

              $response=$db->query("SELECT * FROM events_listing WHERE event_leader_id = $user_id");        
      Severity: Minor
      Found in leader_list.php by phpmd

      UndefinedVariable

      Since: 2.8.0

      Detects when a variable is used that has not been defined before.

      Example

      class Foo
      {
          private function bar()
          {
              // $message is undefined
              echo $message;
          }
      }

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

      Avoid using undefined variables such as '$db' which will lead to PHP notices.
      Open

        $delete = $db->query($sql) or exit("There was an error, contact Webmaster");
      Severity: Minor
      Found in leader_list.php by phpmd

      UndefinedVariable

      Since: 2.8.0

      Detects when a variable is used that has not been defined before.

      Example

      class Foo
      {
          private function bar()
          {
              // $message is undefined
              echo $message;
          }
      }

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

      Avoid using undefined variables such as '$db' which will lead to PHP notices.
      Open

              $wresponse=$db->query("SELECT week_cd FROM week LIMIT 1");
      Severity: Minor
      Found in leader_list.php by phpmd

      UndefinedVariable

      Since: 2.8.0

      Detects when a variable is used that has not been defined before.

      Example

      class Foo
      {
          private function bar()
          {
              // $message is undefined
              echo $message;
          }
      }

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

      Avoid using undefined variables such as '$db' which will lead to PHP notices.
      Open

         $delete = $db->query($sql) or exit("There was an error, contact Webmaster");    
      Severity: Minor
      Found in leader_list.php by phpmd

      UndefinedVariable

      Since: 2.8.0

      Detects when a variable is used that has not been defined before.

      Example

      class Foo
      {
          private function bar()
          {
              // $message is undefined
              echo $message;
          }
      }

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

      Avoid using undefined variables such as '$db' which will lead to PHP notices.
      Open

        $delete = $db->query($sql) or exit("There was an error, contact Webmaster");
      Severity: Minor
      Found in leader_list.php by phpmd

      UndefinedVariable

      Since: 2.8.0

      Detects when a variable is used that has not been defined before.

      Example

      class Foo
      {
          private function bar()
          {
              // $message is undefined
              echo $message;
          }
      }

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

      Avoid using undefined variables such as '$db' which will lead to PHP notices.
      Open

        $delete = $db->query($sql) or exit("There was an error, contact Webmaster");
      Severity: Minor
      Found in leader_list.php by phpmd

      UndefinedVariable

      Since: 2.8.0

      Detects when a variable is used that has not been defined before.

      Example

      class Foo
      {
          private function bar()
          {
              // $message is undefined
              echo $message;
          }
      }

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

      Avoid using undefined variables such as '$db' which will lead to PHP notices.
      Open

                  $uresponse=$db->query("SELECT firstname,lastname,email FROM contact_information WHERE id = $uid");
      Severity: Minor
      Found in leader_list.php by phpmd

      UndefinedVariable

      Since: 2.8.0

      Detects when a variable is used that has not been defined before.

      Example

      class Foo
      {
          private function bar()
          {
              // $message is undefined
              echo $message;
          }
      }

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

      Avoid using undefined variables such as '$db' which will lead to PHP notices.
      Open

         $delete = $db->query($sql) or exit("There was an error, contact Webmaster");    
      Severity: Minor
      Found in leader_list.php by phpmd

      UndefinedVariable

      Since: 2.8.0

      Detects when a variable is used that has not been defined before.

      Example

      class Foo
      {
          private function bar()
          {
              // $message is undefined
              echo $message;
          }
      }

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

      Avoid using undefined variables such as '$db' which will lead to PHP notices.
      Open

           $sig=$db->query("SELECT * FROM events_signup WHERE event_id = $entry AND week=$week_cd AND Factor=$d");
      Severity: Minor
      Found in leader_list.php by phpmd

      UndefinedVariable

      Since: 2.8.0

      Detects when a variable is used that has not been defined before.

      Example

      class Foo
      {
          private function bar()
          {
              // $message is undefined
              echo $message;
          }
      }

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

      Avoid using undefined variables such as '$db' which will lead to PHP notices.
      Open

              $vesponse=$db->query("SELECT position FROM contact_information WHERE id=$user_id LIMIT 1");
      Severity: Minor
      Found in leader_list.php by phpmd

      UndefinedVariable

      Since: 2.8.0

      Detects when a variable is used that has not been defined before.

      Example

      class Foo
      {
          private function bar()
          {
              // $message is undefined
              echo $message;
          }
      }

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

      Avoid using undefined variables such as '$db' which will lead to PHP notices.
      Open

        $delete = $db->query($sql) or exit("There was an error, contact Webmaster");  
      Severity: Minor
      Found in leader_list.php by phpmd

      UndefinedVariable

      Since: 2.8.0

      Detects when a variable is used that has not been defined before.

      Example

      class Foo
      {
          private function bar()
          {
              // $message is undefined
              echo $message;
          }
      }

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

      Avoid using undefined variables such as '$db' which will lead to PHP notices.
      Open

            $subbed = $db->query($new) or die("Submit  $d Failed");  
      Severity: Minor
      Found in leader_list.php by phpmd

      UndefinedVariable

      Since: 2.8.0

      Detects when a variable is used that has not been defined before.

      Example

      class Foo
      {
          private function bar()
          {
              // $message is undefined
              echo $message;
          }
      }

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

      Avoid using undefined variables such as '$db' which will lead to PHP notices.
      Open

              $dsearch=$db->query("SELECT * FROM regular_service_details WHERE event_id=$eid");
      Severity: Minor
      Found in leader_list.php by phpmd

      UndefinedVariable

      Since: 2.8.0

      Detects when a variable is used that has not been defined before.

      Example

      class Foo
      {
          private function bar()
          {
              // $message is undefined
              echo $message;
          }
      }

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

      Avoid using undefined variables such as '$db' which will lead to PHP notices.
      Open

        $delete = $db->query($sql) or exit("There was an error, contact Webmaster");
      Severity: Minor
      Found in leader_list.php by phpmd

      UndefinedVariable

      Since: 2.8.0

      Detects when a variable is used that has not been defined before.

      Example

      class Foo
      {
          private function bar()
          {
              // $message is undefined
              echo $message;
          }
      }

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

      Avoid using undefined variables such as '$db' which will lead to PHP notices.
      Open

        $delete = $db->query($sql) or exit("There was an error, contact Webmaster");
      Severity: Minor
      Found in leader_list.php by phpmd

      UndefinedVariable

      Since: 2.8.0

      Detects when a variable is used that has not been defined before.

      Example

      class Foo
      {
          private function bar()
          {
              // $message is undefined
              echo $message;
          }
      }

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

      Avoid using undefined variables such as '$db' which will lead to PHP notices.
      Open

        $gen=$db->query("SELECT * FROM events_listing WHERE event_id = $entry");
      Severity: Minor
      Found in leader_list.php by phpmd

      UndefinedVariable

      Since: 2.8.0

      Detects when a variable is used that has not been defined before.

      Example

      class Foo
      {
          private function bar()
          {
              // $message is undefined
              echo $message;
          }
      }

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

      Avoid using undefined variables such as '$db' which will lead to PHP notices.
      Open

        $deets=$db->query("SELECT * FROM regular_service_details WHERE event_id = $entry");
      Severity: Minor
      Found in leader_list.php by phpmd

      UndefinedVariable

      Since: 2.8.0

      Detects when a variable is used that has not been defined before.

      Example

      class Foo
      {
          private function bar()
          {
              // $message is undefined
              echo $message;
          }
      }

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

      Avoid using undefined variables such as '$db' which will lead to PHP notices.
      Open

        $subbed = $db->query($new) or die("Submit Failed");
      Severity: Minor
      Found in leader_list.php by phpmd

      UndefinedVariable

      Since: 2.8.0

      Detects when a variable is used that has not been defined before.

      Example

      class Foo
      {
          private function bar()
          {
              // $message is undefined
              echo $message;
          }
      }

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

      Avoid using undefined variables such as '$db' which will lead to PHP notices.
      Open

              $response=$db->query("SELECT * FROM events_listing WHERE event_leader_id = $user_id OR event_type = 'Chapter'");        
      Severity: Minor
      Found in leader_list.php by phpmd

      UndefinedVariable

      Since: 2.8.0

      Detects when a variable is used that has not been defined before.

      Example

      class Foo
      {
          private function bar()
          {
              // $message is undefined
              echo $message;
          }
      }

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

      Avoid using undefined variables such as '$db' which will lead to PHP notices.
      Open

              $wresponse=$db->query("SELECT week_cd FROM week LIMIT 1");
      Severity: Minor
      Found in leader_list.php by phpmd

      UndefinedVariable

      Since: 2.8.0

      Detects when a variable is used that has not been defined before.

      Example

      class Foo
      {
          private function bar()
          {
              // $message is undefined
              echo $message;
          }
      }

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

      Avoid using undefined variables such as '$db' which will lead to PHP notices.
      Open

              $aresponse=$db->query("SELECT user_id,factor,entry_id FROM events_signup WHERE event_id = $eid AND semester='$current_semester'");
      Severity: Minor
      Found in leader_list.php by phpmd

      UndefinedVariable

      Since: 2.8.0

      Detects when a variable is used that has not been defined before.

      Example

      class Foo
      {
          private function bar()
          {
              // $message is undefined
              echo $message;
          }
      }

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

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

          {
              $response=$db->query("SELECT * FROM events_listing WHERE event_leader_id = $user_id");        
          }
      Severity: Minor
      Found in leader_list.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 show_active uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
      Open

              {
                  $cancel = "<sup><a href='leader_list.php?delete_event=$eid'>Delete Event?</a></sup>";
                  if ($result['closed'] == 1)
                  {
                      $submit = "<sup><a href='leader_list.php?open=$eid'>Open?</a></sup>";
      Severity: Minor
      Found in leader_list.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 show_active uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
      Open

              {        
                  $submit = "submitted";
              }
      Severity: Minor
      Found in leader_list.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 show_active uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
      Open

              {        
                  $cancel = "<sup><a href='leader_list.php?uncancel=$eid'>Uncancel?</a></sup>";
              }
      Severity: Minor
      Found in leader_list.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 show_active uses an else expression. Else clauses are basically not necessary and you can simplify the code by not using them.
      Open

                  {
                      $submit = "<sup><a href='leader_list.php?end=$eid'>Close?</a></sup>";
                  }
      Severity: Minor
      Found in leader_list.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 function submit_event() contains an exit expression.
      Open

        $subbed = $db->query($new) or die("Submit Failed");
      Severity: Minor
      Found in leader_list.php by phpmd

      ExitExpression

      Since: 0.2

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

      Example

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

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

      The function close_event() contains an exit expression.
      Open

         $delete = $db->query($sql) or exit("There was an error, contact Webmaster");    
      Severity: Minor
      Found in leader_list.php by phpmd

      ExitExpression

      Since: 0.2

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

      Example

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

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

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

         $delete = $db->query($sql) or exit("There was an error, contact Webmaster");    
      Severity: Minor
      Found in leader_list.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 '$db'.
      Open

         $delete = $db->query($sql) or exit("There was an error, contact Webmaster");    
      Severity: Minor
      Found in leader_list.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 '$db'.
      Open

        $delete = $db->query($sql) or exit("There was an error, contact Webmaster");
      Severity: Minor
      Found in leader_list.php by phpmd

      UnusedLocalVariable

      Since: 0.2

      Detects when a local variable is declared and/or assigned, but not used.

      Example

      class Foo {
          public function doSomething()
          {
              $i = 5; // Unused
          }
      }

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

      The function uncancel_event() contains an exit expression.
      Open

        $delete = $db->query($sql) or exit("There was an error, contact Webmaster");
      Severity: Minor
      Found in leader_list.php by phpmd

      ExitExpression

      Since: 0.2

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

      Example

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

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

      The function submit_event() contains an exit expression.
      Open

        $delete = $db->query($sql) or exit("There was an error, contact Webmaster");
      Severity: Minor
      Found in leader_list.php by phpmd

      ExitExpression

      Since: 0.2

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

      Example

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

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

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

        $delete = $db->query($sql) or exit("There was an error, contact Webmaster");
      Severity: Minor
      Found in leader_list.php by phpmd

      UnusedLocalVariable

      Since: 0.2

      Detects when a local variable is declared and/or assigned, but not used.

      Example

      class Foo {
          public function doSomething()
          {
              $i = 5; // Unused
          }
      }

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

      The function open_event() contains an exit expression.
      Open

         $delete = $db->query($sql) or exit("There was an error, contact Webmaster");    
      Severity: Minor
      Found in leader_list.php by phpmd

      ExitExpression

      Since: 0.2

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

      Example

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

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

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

         $delete = $db->query($sql) or exit("There was an error, contact Webmaster");    
      Severity: Minor
      Found in leader_list.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 '$delete'.
      Open

        $delete = $db->query($sql) or exit("There was an error, contact Webmaster");
      Severity: Minor
      Found in leader_list.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 '$db'.
      Open

        $delete = $db->query($sql) or exit("There was an error, contact Webmaster");
      Severity: Minor
      Found in leader_list.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 '$db'.
      Open

         $delete = $db->query($sql) or exit("There was an error, contact Webmaster");    
      Severity: Minor
      Found in leader_list.php by phpmd

      UnusedLocalVariable

      Since: 0.2

      Detects when a local variable is declared and/or assigned, but not used.

      Example

      class Foo {
          public function doSomething()
          {
              $i = 5; // Unused
          }
      }

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

      The function delete_event_and_entries() contains an exit expression.
      Open

        $delete = $db->query($sql) or exit("There was an error, contact Webmaster");  
      Severity: Minor
      Found in leader_list.php by phpmd

      ExitExpression

      Since: 0.2

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

      Example

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

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

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

        $delete = $db->query($sql) or exit("There was an error, contact Webmaster");  
      Severity: Minor
      Found in leader_list.php by phpmd

      UnusedLocalVariable

      Since: 0.2

      Detects when a local variable is declared and/or assigned, but not used.

      Example

      class Foo {
          public function doSomething()
          {
              $i = 5; // Unused
          }
      }

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

      The function delete_event_and_entries() contains an exit expression.
      Open

        $delete = $db->query($sql) or exit("There was an error, contact Webmaster");
      Severity: Minor
      Found in leader_list.php by phpmd

      ExitExpression

      Since: 0.2

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

      Example

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

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

      The function cancel_event() contains an exit expression.
      Open

        $delete = $db->query($sql) or exit("There was an error, contact Webmaster");
      Severity: Minor
      Found in leader_list.php by phpmd

      ExitExpression

      Since: 0.2

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

      Example

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

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

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

        $delete = $db->query($sql) or exit("There was an error, contact Webmaster");
      Severity: Minor
      Found in leader_list.php by phpmd

      UnusedLocalVariable

      Since: 0.2

      Detects when a local variable is declared and/or assigned, but not used.

      Example

      class Foo {
          public function doSomething()
          {
              $i = 5; // Unused
          }
      }

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

      The function submit_event() contains an exit expression.
      Open

            $subbed = $db->query($new) or die("Submit  $d Failed");  
      Severity: Minor
      Found in leader_list.php by phpmd

      ExitExpression

      Since: 0.2

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

      Example

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

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

      The function delete_entry() contains an exit expression.
      Open

        $delete = $db->query($sql) or exit("There was an error, contact Webmaster");
      Severity: Minor
      Found in leader_list.php by phpmd

      ExitExpression

      Since: 0.2

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

      Example

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

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

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

        $delete = $db->query($sql) or exit("There was an error, contact Webmaster");
      Severity: Minor
      Found in leader_list.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 '$subbed'.
      Open

        $subbed = $db->query($new) or die("Submit Failed");
      Severity: Minor
      Found in leader_list.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 '$delete'.
      Open

        $delete = $db->query($sql) or exit("There was an error, contact Webmaster");
      Severity: Minor
      Found in leader_list.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 '$week_cd'.
      Open

              $week_cd = $wres['week_cd'];
      Severity: Minor
      Found in leader_list.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

      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 27 and the first side effect is on line 2.
      Open

      <?php
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

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

            $sg=mysqli_fetch_array($sig);    
      Severity: Minor
      Found in leader_list.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

      TRUE, FALSE and NULL must be lowercase; expected "true" but found "True"
      Open

      $active_page = True;
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      TRUE, FALSE and NULL must be lowercase; expected "false" but found "False"
      Open

      $public_page = False;
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              $wresponse=$db->query("SELECT week_cd FROM week LIMIT 1");
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

         $delete = $db->query($sql) or exit("There was an error, contact Webmaster");    
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      TRUE, FALSE and NULL must be lowercase; expected "false" but found "False"
      Open

      $exec_page = False;
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

         $delete = $db->query($sql) or exit("There was an error, contact Webmaster");    
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              $entry = $_GET['cancel'];
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              $response=$db->query("SELECT * FROM events_listing WHERE event_leader_id = $user_id OR event_type = 'Chapter'");        
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              else
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              $response=$db->query("SELECT * FROM events_listing WHERE event_leader_id = $user_id");        
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

                      $submit = "<sup><a href='leader_list.php?end=$eid'>Close?</a></sup>";
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              ?>
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              //loop for each participant. Display name, factor, and email!
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              $wres=mysqli_fetch_array($wresponse);
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

          {
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

          }
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

                  $cancel = "<sup><a href='leader_list.php?cancel=$eid'>Cancel?</a></sup>";
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              {        
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

                  if ($result['closed'] == 1)
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

                  $uresult=mysqli_fetch_array($uresponse);
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

            $subbed = $db->query($new) or die("Submit  $d Failed");  
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              $entry = $_GET['uncancel'];
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              submit_event($entry);
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

          else if (isset($_GET['end'])) {
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              if ($daily['cancel'] == 0)
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

          $user_id = $_SESSION['sessionID'];
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

                  $submit = "submitted";
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

             include('mysql_access.php');
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              $entry = $_GET['delete'];
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

          }
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              uncancel_event($entry);
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

          }
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              delete_event_and_entries($eid);
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              $week_cd = $wres['week_cd'];
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

                  $submit = "<sup><a href='leader_list.php?submit=$eid'>Submit?</a></sup>";
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              {        
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              }
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              <?php
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              {
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              else
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

                  }
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              $aresponse=$db->query("SELECT user_id,factor,entry_id FROM events_signup WHERE event_id = $eid AND semester='$current_semester'");
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

                  $count++;
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

                  $uid = $aresult['user_id'];
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              ?>
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

          }
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

          }
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              $eid = $_GET['open'];
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              close_event($eid);
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

          {
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

          }
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

          while($result=mysqli_fetch_array($response))
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              //set cancel or uncancel
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              {        
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              else
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              <tr><td colspan="2"><?= $result['event_name'] ?></td><td>Type: <?= $result['event_type'] ?> </td>
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              global $current_semester;
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

                  $uresponse=$db->query("SELECT firstname,lastname,email FROM contact_information WHERE id = $uid");
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

                  echo "<tr><td>" . $count . "</td><td>" . $uresult['firstname'] . " " . $uresult['lastname'] . "</td><td>" . $uresult['email'] . "<td></td><td><sup><a href='leader_list.php?delete=$entry'>Delete?</a></sup></td>";
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

                  echo "</tr>";
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

            $sg=mysqli_fetch_array($sig);    
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

          $n_id = $sg['user_id'];
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              $dsearch=$db->query("SELECT * FROM regular_service_details WHERE event_id=$eid");
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

                  $cancel = "<sup><a href='leader_list.php?uncancel=$eid'>Uncancel?</a></sup>";
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              //set submit or null
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              }
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              <tr><th>#</th><th>Name</th><th>Email</th><th>Note</th><th>Delete?</th></tr>
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              <?php
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

          if (isset($sg['user_id'])) //if someone is signed up in this factor
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

            $new = "INSERT INTO recorded_hours (user_id,month,day,year,date,semester,description,hours,servicetype,event,youth) VALUES($n_id,1,1,2017,0,'Spring 2017','$desc',$hrs,'$svc_type','$event_name',$yth)";
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

          else if (isset($_GET['submit'])) {
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

          else if (isset($_GET['open'])) {
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              open_event($eid);
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

          if($vesult['position'] == 'Recording Secretary')
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              $response=$db->query("SELECT * FROM events_listing WHERE event_leader_id = $user_id OR event_type = 'Chapter'");        
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

          else
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              {
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

                  else
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              $count = 0;
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              while($aresult=mysqli_fetch_array($aresponse))
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

          if (isset($_GET['delete'])) {
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              $entry = $_GET['submit'];
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

          else if (isset($_GET['delete_event'])) {
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              if ($daily['closed'] == 0)
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              }
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

           $sig=$db->query("SELECT * FROM events_signup WHERE event_id = $entry AND week=$week_cd AND Factor=$d");
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

          }
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

          else if (isset($_GET['uncancel'])) {
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

          }
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              $eid = $_GET['end'];
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              $vesponse=$db->query("SELECT position FROM contact_information WHERE id=$user_id LIMIT 1");
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

            $sg=mysqli_fetch_array($sig);    
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

          }
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              $response=$db->query("SELECT * FROM events_listing WHERE event_leader_id = $user_id");        
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

          {
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              {
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

                  {
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              {
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              }
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

          echo "<h1>Events you are leading:</h1>";
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              cancel_event($entry);
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

          }
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              $eid = $result['event_id'];
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              $week_cd = $wres['week_cd'];
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              {        
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

          else if (isset($_GET['cancel'])) {
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              $wres=mysqli_fetch_array($wresponse);
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

                  {
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

                  $cancel = "<sup><a href='leader_list.php?delete_event=$eid'>Delete Event?</a></sup>";
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

                  }
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              <tr><td colspan="5"><?= $result['event_description'] ?></td></tr>
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Space found after opening bracket of FOR loop
      Open

        for ( $d=1; $d<=$cap; $d++)
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

          }
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              $vesult=mysqli_fetch_array($vesponse);
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              }
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              {
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              //$aresponse=$db->query("SELECT user_id,factor,entry_id FROM events_signup WHERE event_id = $eid AND week = $week_cd");
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

                  $entry = $aresult['entry_id'];
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              delete_entry($entry);
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              $eid = $_GET['delete_event'];
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

          //if rec sec, display all chapter events first
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

          {
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              $wresponse=$db->query("SELECT week_cd FROM week LIMIT 1");
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              $daily=mysqli_fetch_array($dsearch);
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              if($result['event_type'] == 'Regular Service')
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              }
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              }
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

                      $submit = "<sup><a href='leader_list.php?open=$eid'>Open?</a></sup>";
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              <table>
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              <td><?= $submit ?></td><td><?= $cancel ?></td></tr>
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Spaces must be used for alignment; tabs are not allowed
      Open

              </table>
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      End of line character is invalid; expected "\n" but found "\r\n"
      Open

      <?php
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line exceeds 120 characters; contains 206 characters
      Open

        $new = "INSERT INTO recorded_hours (user_id,month,day,year,date,semester,description,hours,servicetype,event,youth) VALUES ($user_id,1,1,2017,0,'Spring 2017','$desc',$hrs,'$svc_type','$event_name',$yth)";
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line exceeds 120 characters; contains 138 characters
      Open

              $aresponse=$db->query("SELECT user_id,factor,entry_id FROM events_signup WHERE event_id = $eid AND semester='$current_semester'");
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line exceeds 120 characters; contains 223 characters
      Open

                  echo "<tr><td>" . $count . "</td><td>" . $uresult['firstname'] . " " . $uresult['lastname'] . "</td><td>" . $uresult['email'] . "<td></td><td><sup><a href='leader_list.php?delete=$entry'>Delete?</a></sup></td>";
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line exceeds 120 characters; contains 204 characters
      Open

            $new = "INSERT INTO recorded_hours (user_id,month,day,year,date,semester,description,hours,servicetype,event,youth) VALUES($n_id,1,1,2017,0,'Spring 2017','$desc',$hrs,'$svc_type','$event_name',$yth)";
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line exceeds 120 characters; contains 128 characters
      Open

              $response=$db->query("SELECT * FROM events_listing WHERE event_leader_id = $user_id OR event_type = 'Chapter'");        
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line exceeds 120 characters; contains 127 characters
      Open

              //$aresponse=$db->query("SELECT user_id,factor,entry_id FROM events_signup WHERE event_id = $eid AND week = $week_cd");
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line indented incorrectly; expected at least 4 spaces, found 3
      Open

         include ('mysql_access.php');
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Space before opening parenthesis of function call prohibited
      Open

         include ('mysql_access.php');
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line indented incorrectly; expected at least 4 spaces, found 2
      Open

        $sql = "DELETE FROM `events_signup` WHERE `entry_id` = '$entry' LIMIT 1";
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Space before opening parenthesis of function call prohibited
      Open

        include ('mysql_access.php');
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line indented incorrectly; expected at least 4 spaces, found 2
      Open

        $sql = "UPDATE regular_service_details SET cancel=0 WHERE event_id=$entry LIMIT 1";
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line indented incorrectly; expected at least 4 spaces, found 2
      Open

        include ('mysql_access.php');
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line indented incorrectly; expected at least 4 spaces, found 2
      Open

        $delete = $db->query($sql) or exit("There was an error, contact Webmaster");
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line indented incorrectly; expected at least 4 spaces, found 2
      Open

        $user_id = $_SESSION['sessionID'];
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Space before opening parenthesis of function call prohibited
      Open

      require_once ('session.php');
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Opening brace should be on a new line
      Open

      function submit_event($entry) {
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line indented incorrectly; expected at least 4 spaces, found 3
      Open

         include ('mysql_access.php');
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Space before opening parenthesis of function call prohibited
      Open

        include ('mysql_access.php');
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line indented incorrectly; expected at least 4 spaces, found 2
      Open

        include ('mysql_access.php');
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line indented incorrectly; expected at least 4 spaces, found 2
      Open

        $delete = $db->query($sql) or exit("There was an error, contact Webmaster");
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line indented incorrectly; expected at least 4 spaces, found 2
      Open

        $delete = $db->query($sql) or exit("There was an error, contact Webmaster");
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line indented incorrectly; expected at least 4 spaces, found 2
      Open

        $sql = "UPDATE regular_service_details SET cancel=1 WHERE event_id=$entry LIMIT 1";
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Space before opening parenthesis of function call prohibited
      Open

         include ('mysql_access.php');
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line indented incorrectly; expected at least 4 spaces, found 2
      Open

        include ('mysql_access.php');
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Opening brace should be on a new line
      Open

      function cancel_event($entry) {
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Opening brace should be on a new line
      Open

      function uncancel_event($entry) {
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line indented incorrectly; expected at least 4 spaces, found 2
      Open

        include ('mysql_access.php');
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Whitespace found at end of line
      Open

         $delete = $db->query($sql) or exit("There was an error, contact Webmaster");    
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Space before opening parenthesis of function call prohibited
      Open

        include ('mysql_access.php');
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Space before opening parenthesis of function call prohibited
      Open

        include ('mysql_access.php');
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line indented incorrectly; expected at least 4 spaces, found 3
      Open

         $delete = $db->query($sql) or exit("There was an error, contact Webmaster");    
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line indented incorrectly; expected at least 4 spaces, found 3
      Open

         $sql = "UPDATE events_listing SET closed=0 WHERE event_id=$eid LIMIT 1";
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line indented incorrectly; expected at least 4 spaces, found 2
      Open

        $delete = $db->query($sql) or exit("There was an error, contact Webmaster");
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line indented incorrectly; expected at least 4 spaces, found 2
      Open

        $sql = "DELETE FROM `events_signup` WHERE `event_id` = '$eid'";
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Space before opening parenthesis of function call prohibited
      Open

        include ('mysql_access.php');
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line indented incorrectly; expected at least 4 spaces, found 3
      Open

         $sql = "UPDATE events_listing SET closed=1 WHERE event_id=$eid LIMIT 1";
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Whitespace found at end of line
      Open

        $delete = $db->query($sql) or exit("There was an error, contact Webmaster");  
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line indented incorrectly; expected at least 4 spaces, found 3
      Open

         $delete = $db->query($sql) or exit("There was an error, contact Webmaster");    
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Opening brace should be on a new line
      Open

      function delete_entry($entry) {
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line indented incorrectly; expected at least 4 spaces, found 2
      Open

        include ('mysql_access.php');
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Space before opening parenthesis of function call prohibited
      Open

      require_once ('mysql_access.php');
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line indented incorrectly; expected at least 4 spaces, found 2
      Open

        $delete = $db->query($sql) or exit("There was an error, contact Webmaster");  
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line indented incorrectly; expected at least 4 spaces, found 2
      Open

        $sql = "DELETE FROM `events_listing` WHERE `event_id` = '$eid' LIMIT 1";
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Whitespace found at end of line
      Open

         $delete = $db->query($sql) or exit("There was an error, contact Webmaster");    
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Usage of ELSE IF is discouraged; use ELSEIF instead
      Open

          else if (isset($_GET['uncancel'])) {
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Expected 1 space after closing brace; newline found
      Open

          }
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Expected 1 space after closing brace; newline found
      Open

          }
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Expected 1 space after closing parenthesis; found 6
      Open

          while($result=mysqli_fetch_array($response))
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Expected 1 space after closing parenthesis; found 14
      Open

                  if ($result['closed'] == 1)
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Whitespace found at end of line
      Open

              $response=$db->query("SELECT * FROM events_listing WHERE event_leader_id = $user_id");        
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line indented incorrectly; expected 12 spaces, found 8
      Open

              if ($daily['cancel'] == 0)
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Expected 1 space after ELSE keyword; newline found
      Open

              else
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Expected 1 space after closing brace; newline found
      Open

          }
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Expected 1 space after closing brace; newline found
      Open

          }
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Whitespace found at end of line
      Open

            $sg=mysqli_fetch_array($sig);    
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line indented incorrectly; expected at least 12 spaces, found 4
      Open

          $n_id = $sg['user_id'];
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line indented incorrectly; expected at least 4 spaces, found 2
      Open

        $dts=mysqli_fetch_array($deets);
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Usage of ELSE IF is discouraged; use ELSEIF instead
      Open

          else if (isset($_GET['submit'])) {
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line indented incorrectly; expected at least 4 spaces, found 2
      Open

        $desc = $gens['event_description'] . " Week #" . $week_cd;
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Expected 1 space after closing parenthesis; found " //if someone is signed up in this factor\n "
      Open

          if (isset($sg['user_id'])) //if someone is signed up in this factor
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line indented incorrectly; expected at least 12 spaces, found 4
      Open

            $subbed = $db->query($new) or die("Submit  $d Failed");  
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line indented incorrectly; expected 4 spaces, found 2
      Open

        }
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line indented incorrectly; expected at least 12 spaces, found 8
      Open

              {
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Expected 1 space after closing parenthesis; found 6
      Open

          if($vesult['position'] == 'Recording Secretary')
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Expected 1 space after ELSE keyword; newline found
      Open

          else
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Expected 1 space after closing brace; newline found
      Open

              }
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Expected 1 space after closing parenthesis; found 4
      Open

        for ( $d=1; $d<=$cap; $d++)
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line indented incorrectly; expected at least 4 spaces, found 2
      Open

        $delete = $db->query($sql) or exit("There was an error, contact Webmaster");
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Usage of ELSE IF is discouraged; use ELSEIF instead
      Open

          else if (isset($_GET['delete_event'])) {
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Expected 1 space after ELSE keyword; newline found
      Open

              else
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Expected 1 space after closing parenthesis; found 10
      Open

              if ($daily['closed'] == 0)
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Expected 1 space after ELSE keyword; newline found
      Open

                  else
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line indented incorrectly; expected at least 4 spaces, found 2
      Open

        $yth = $dts['youth'];
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line indented incorrectly; expected at least 4 spaces, found 2
      Open

        $gens=mysqli_fetch_array($gen);
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line indented incorrectly; expected at least 8 spaces, found 4
      Open

            $sg=mysqli_fetch_array($sig);    
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line indented incorrectly; expected 8 spaces, found 4
      Open

          }
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Expected 1 space after closing brace; newline found
      Open

          }
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Expected 1 space after IF keyword; 0 found
      Open

          if($vesult['position'] == 'Recording Secretary')
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line indented incorrectly; expected at least 16 spaces, found 12
      Open

                  $cancel = "<sup><a href='leader_list.php?cancel=$eid'>Cancel?</a></sup>";
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Expected 1 space after closing parenthesis; found 10
      Open

              while($aresult=mysqli_fetch_array($aresponse))
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line indented incorrectly; expected at least 4 spaces, found 2
      Open

        $gen=$db->query("SELECT * FROM events_listing WHERE event_id = $entry");
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line indented incorrectly; expected at least 4 spaces, found 2
      Open

        {
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line indented incorrectly; expected at least 8 spaces, found 4
      Open

           $sig=$db->query("SELECT * FROM events_signup WHERE event_id = $entry AND week=$week_cd AND Factor=$d");
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Usage of ELSE IF is discouraged; use ELSEIF instead
      Open

          else if (isset($_GET['cancel'])) {
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Usage of ELSE IF is discouraged; use ELSEIF instead
      Open

          else if (isset($_GET['end'])) {
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Expected 1 space after IF keyword; 0 found
      Open

              if($result['event_type'] == 'Regular Service')
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line indented incorrectly; expected 12 spaces, found 8
      Open

              }
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line indented incorrectly; expected at least 16 spaces, found 12
      Open

                  $submit = "<sup><a href='leader_list.php?submit=$eid'>Submit?</a></sup>";
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line indented incorrectly; expected at least 4 spaces, found 2
      Open

        $deets=$db->query("SELECT * FROM regular_service_details WHERE event_id = $entry");
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line indented incorrectly; expected 4 spaces, found 2
      Open

        for ( $d=1; $d<=$cap; $d++)
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Whitespace found at end of line
      Open

              $response=$db->query("SELECT * FROM events_listing WHERE event_leader_id = $user_id OR event_type = 'Chapter'");        
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Expected 1 space after closing brace; newline found
      Open

          }
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Expected 1 space after closing parenthesis; found 10
      Open

              if($result['event_type'] == 'Regular Service')
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Expected 1 space after closing brace; newline found
      Open

                  }
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line indented incorrectly; expected at least 4 spaces, found 2
      Open

        $new = "INSERT INTO recorded_hours (user_id,month,day,year,date,semester,description,hours,servicetype,event,youth) VALUES ($user_id,1,1,2017,0,'Spring 2017','$desc',$hrs,'$svc_type','$event_name',$yth)";
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line indented incorrectly; expected at least 4 spaces, found 2
      Open

        $subbed = $db->query($new) or die("Submit Failed");
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Whitespace found at end of line
      Open

            $subbed = $db->query($new) or die("Submit  $d Failed");  
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Expected 1 space after WHILE keyword; 0 found
      Open

          while($result=mysqli_fetch_array($response))
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line indented incorrectly; expected 12 spaces, found 8
      Open

              if ($daily['closed'] == 0)
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line indented incorrectly; expected 12 spaces, found 8
      Open

              }
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line indented incorrectly; expected at least 16 spaces, found 12
      Open

                  $cancel = "<sup><a href='leader_list.php?uncancel=$eid'>Uncancel?</a></sup>";
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Whitespace found at end of line
      Open

              {        
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line indented incorrectly; expected 12 spaces, found 8
      Open

              }
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line indented incorrectly; expected at least 4 spaces, found 2
      Open

        $hrs = $gens['S_val'];
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Expected 1 space after closing brace; newline found
      Open

              }
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line indented incorrectly; expected 12 spaces, found 8
      Open

              else
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line indented incorrectly; expected at least 16 spaces, found 12
      Open

                  $submit = "submitted";
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line indented incorrectly; expected at least 4 spaces, found 2
      Open

        $svc_type = $dts['service_type'];
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line indented incorrectly; expected at least 12 spaces, found 4
      Open

            $new = "INSERT INTO recorded_hours (user_id,month,day,year,date,semester,description,hours,servicetype,event,youth) VALUES($n_id,1,1,2017,0,'Spring 2017','$desc',$hrs,'$svc_type','$event_name',$yth)";
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Opening brace should be on a new line
      Open

      function show_active() {
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Expected 1 space after closing parenthesis; found 10
      Open

              if ($daily['cancel'] == 0)
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Whitespace found at end of line
      Open

              {        
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line indented incorrectly; expected at least 4 spaces, found 2
      Open

        $cap = $gens['event_cap'];
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line indented incorrectly; expected at least 4 spaces, found 2
      Open

        $sql = "UPDATE regular_service_details SET closed=1 WHERE event_id=$entry LIMIT 1";
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Expected 1 space after closing brace; newline found
      Open

              }
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line indented incorrectly; expected at least 12 spaces, found 8
      Open

              {        
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line indented incorrectly; expected at least 12 spaces, found 8
      Open

              {
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Expected 1 space after ELSE keyword; newline found
      Open

              else
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Expected 0 spaces after opening bracket; 1 found
      Open

        for ( $d=1; $d<=$cap; $d++)
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line indented incorrectly; expected 8 spaces, found 4
      Open

          if (isset($sg['user_id'])) //if someone is signed up in this factor
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line indented incorrectly; expected at least 8 spaces, found 4
      Open

          {
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Expected 1 space after closing brace; newline found
      Open

          }
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Usage of ELSE IF is discouraged; use ELSEIF instead
      Open

          else if (isset($_GET['open'])) {
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line indented incorrectly; expected 12 spaces, found 8
      Open

              else
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Expected 1 space after WHILE keyword; 0 found
      Open

              while($aresult=mysqli_fetch_array($aresponse))
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line indented incorrectly; expected at least 4 spaces, found 2
      Open

        $event_name = $gens['event_name'];
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line indented incorrectly; expected 12 spaces, found 8
      Open

              }
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      Line indented incorrectly; expected at least 12 spaces, found 8
      Open

              {        
      Severity: Minor
      Found in leader_list.php by phpcodesniffer

      The variable $n_id is not named in camelCase.
      Open

      function submit_event($entry) {
        include ('mysql_access.php');
        $user_id = $_SESSION['sessionID'];
      
              $wresponse=$db->query("SELECT week_cd FROM week LIMIT 1");
      Severity: Minor
      Found in leader_list.php by phpmd

      CamelCaseVariableName

      Since: 0.2

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

      Example

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

      Source

      The variable $current_semester is not named in camelCase.
      Open

      function show_active() {
          echo "<h1>Events you are leading:</h1>";
      
          $user_id = $_SESSION['sessionID'];
             include('mysql_access.php');
      Severity: Minor
      Found in leader_list.php by phpmd

      CamelCaseVariableName

      Since: 0.2

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

      Example

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

      Source

      The variable $user_id is not named in camelCase.
      Open

      function submit_event($entry) {
        include ('mysql_access.php');
        $user_id = $_SESSION['sessionID'];
      
              $wresponse=$db->query("SELECT week_cd FROM week LIMIT 1");
      Severity: Minor
      Found in leader_list.php by phpmd

      CamelCaseVariableName

      Since: 0.2

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

      Example

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

      Source

      The variable $current_semester is not named in camelCase.
      Open

      function show_active() {
          echo "<h1>Events you are leading:</h1>";
      
          $user_id = $_SESSION['sessionID'];
             include('mysql_access.php');
      Severity: Minor
      Found in leader_list.php by phpmd

      CamelCaseVariableName

      Since: 0.2

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

      Example

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

      Source

      The variable $user_id is not named in camelCase.
      Open

      function show_active() {
          echo "<h1>Events you are leading:</h1>";
      
          $user_id = $_SESSION['sessionID'];
             include('mysql_access.php');
      Severity: Minor
      Found in leader_list.php by phpmd

      CamelCaseVariableName

      Since: 0.2

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

      Example

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

      Source

      The variable $week_cd is not named in camelCase.
      Open

      function show_active() {
          echo "<h1>Events you are leading:</h1>";
      
          $user_id = $_SESSION['sessionID'];
             include('mysql_access.php');
      Severity: Minor
      Found in leader_list.php by phpmd

      CamelCaseVariableName

      Since: 0.2

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

      Example

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

      Source

      The variable $week_cd is not named in camelCase.
      Open

      function submit_event($entry) {
        include ('mysql_access.php');
        $user_id = $_SESSION['sessionID'];
      
              $wresponse=$db->query("SELECT week_cd FROM week LIMIT 1");
      Severity: Minor
      Found in leader_list.php by phpmd

      CamelCaseVariableName

      Since: 0.2

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

      Example

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

      Source

      The variable $week_cd is not named in camelCase.
      Open

      function submit_event($entry) {
        include ('mysql_access.php');
        $user_id = $_SESSION['sessionID'];
      
              $wresponse=$db->query("SELECT week_cd FROM week LIMIT 1");
      Severity: Minor
      Found in leader_list.php by phpmd

      CamelCaseVariableName

      Since: 0.2

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

      Example

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

      Source

      The variable $n_id is not named in camelCase.
      Open

      function submit_event($entry) {
        include ('mysql_access.php');
        $user_id = $_SESSION['sessionID'];
      
              $wresponse=$db->query("SELECT week_cd FROM week LIMIT 1");
      Severity: Minor
      Found in leader_list.php by phpmd

      CamelCaseVariableName

      Since: 0.2

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

      Example

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

      Source

      The variable $user_id is not named in camelCase.
      Open

      function show_active() {
          echo "<h1>Events you are leading:</h1>";
      
          $user_id = $_SESSION['sessionID'];
             include('mysql_access.php');
      Severity: Minor
      Found in leader_list.php by phpmd

      CamelCaseVariableName

      Since: 0.2

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

      Example

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

      Source

      The variable $event_name is not named in camelCase.
      Open

      function submit_event($entry) {
        include ('mysql_access.php');
        $user_id = $_SESSION['sessionID'];
      
              $wresponse=$db->query("SELECT week_cd FROM week LIMIT 1");
      Severity: Minor
      Found in leader_list.php by phpmd

      CamelCaseVariableName

      Since: 0.2

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

      Example

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

      Source

      The variable $event_name is not named in camelCase.
      Open

      function submit_event($entry) {
        include ('mysql_access.php');
        $user_id = $_SESSION['sessionID'];
      
              $wresponse=$db->query("SELECT week_cd FROM week LIMIT 1");
      Severity: Minor
      Found in leader_list.php by phpmd

      CamelCaseVariableName

      Since: 0.2

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

      Example

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

      Source

      The variable $svc_type is not named in camelCase.
      Open

      function submit_event($entry) {
        include ('mysql_access.php');
        $user_id = $_SESSION['sessionID'];
      
              $wresponse=$db->query("SELECT week_cd FROM week LIMIT 1");
      Severity: Minor
      Found in leader_list.php by phpmd

      CamelCaseVariableName

      Since: 0.2

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

      Example

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

      Source

      The variable $svc_type is not named in camelCase.
      Open

      function submit_event($entry) {
        include ('mysql_access.php');
        $user_id = $_SESSION['sessionID'];
      
              $wresponse=$db->query("SELECT week_cd FROM week LIMIT 1");
      Severity: Minor
      Found in leader_list.php by phpmd

      CamelCaseVariableName

      Since: 0.2

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

      Example

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

      Source

      The variable $user_id is not named in camelCase.
      Open

      function submit_event($entry) {
        include ('mysql_access.php');
        $user_id = $_SESSION['sessionID'];
      
              $wresponse=$db->query("SELECT week_cd FROM week LIMIT 1");
      Severity: Minor
      Found in leader_list.php by phpmd

      CamelCaseVariableName

      Since: 0.2

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

      Example

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

      Source

      The variable $user_id is not named in camelCase.
      Open

      function show_active() {
          echo "<h1>Events you are leading:</h1>";
      
          $user_id = $_SESSION['sessionID'];
             include('mysql_access.php');
      Severity: Minor
      Found in leader_list.php by phpmd

      CamelCaseVariableName

      Since: 0.2

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

      Example

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

      Source

      The variable $user_id is not named in camelCase.
      Open

      function show_active() {
          echo "<h1>Events you are leading:</h1>";
      
          $user_id = $_SESSION['sessionID'];
             include('mysql_access.php');
      Severity: Minor
      Found in leader_list.php by phpmd

      CamelCaseVariableName

      Since: 0.2

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

      Example

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

      Source

      The variable $week_cd is not named in camelCase.
      Open

      function submit_event($entry) {
        include ('mysql_access.php');
        $user_id = $_SESSION['sessionID'];
      
              $wresponse=$db->query("SELECT week_cd FROM week LIMIT 1");
      Severity: Minor
      Found in leader_list.php by phpmd

      CamelCaseVariableName

      Since: 0.2

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

      Example

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

      Source

      The variable $svc_type is not named in camelCase.
      Open

      function submit_event($entry) {
        include ('mysql_access.php');
        $user_id = $_SESSION['sessionID'];
      
              $wresponse=$db->query("SELECT week_cd FROM week LIMIT 1");
      Severity: Minor
      Found in leader_list.php by phpmd

      CamelCaseVariableName

      Since: 0.2

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

      Example

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

      Source

      The variable $event_name is not named in camelCase.
      Open

      function submit_event($entry) {
        include ('mysql_access.php');
        $user_id = $_SESSION['sessionID'];
      
              $wresponse=$db->query("SELECT week_cd FROM week LIMIT 1");
      Severity: Minor
      Found in leader_list.php by phpmd

      CamelCaseVariableName

      Since: 0.2

      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