APO-Epsilon/apo-website

View on GitHub
r8conf2016/permissions.php

Summary

Maintainability
A
0 mins
Test Coverage

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

<?php
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

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

                $exec_authorized = True;
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

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

        $exec_authorized = False;
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

            include('../mysql_access.php');
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

        } elseif($exec_page){
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

    echo "<p>There's been an error. This page doesn't have any content.</p>";
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

    require_once('login_form.php');
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

    }
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

    echo "<h2>Sorry</h2>";
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

            show_insuff_permissions();
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

                $exec_authorized = True;
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

        }
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

        } elseif($active_page){
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

            show_public();
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

            show_public();
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

    } else{
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

        show_error();
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

        if($exec_authorized){
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

            show_exec();
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

            show_insuff_permissions();
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

    if($public_page){
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

            $sql = "SELECT * FROM exec_permissions WHERE position = \"{$_SESSION['sessionposition']}\" AND page = \"{$_SERVER['PHP_SELF']}\";";
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

        }
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

        if($exec_page){
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

            }
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

            show_active();
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

        } elseif($public_page){
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

            show_active();
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

    echo "<div class=\"small-12 columns\">";
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

    echo "</div>";
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

    } elseif($exec_page || $active_page){
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

            if(mysqli_num_rows($result) != 0){
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

        if($active_page){
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

    echo "<p>Only certain members of exec can view this page.</p>";
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

    echo "</div>";
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

        $exec_authorized = False;
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

            $result = $db->query($sql);
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

            show_error();
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

        } elseif($public_page){
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

    }
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

    echo "<h2>Oops</h2>";
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Line exceeds 120 characters; contains 143 characters
Open

            $sql = "SELECT * FROM exec_permissions WHERE position = \"{$_SESSION['sessionposition']}\" AND page = \"{$_SERVER['PHP_SELF']}\";";
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

        } elseif($exec_page){
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

        } else{
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

            show_error();
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

        show_login();
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

    if($_SESSION['sessionexec'] == 1){
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

    } else{
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

        } else{
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

        show_public();
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

    echo "<div class=\"small-12 columns\">";
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Spaces must be used to indent lines; tabs are not allowed
Open

        }
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Expected 1 space after IF keyword; 0 found
Open

if(isset($_SESSION['sessionID'])){
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Expected 1 space after closing parenthesis; found 0
Open

        if($exec_page){
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Expected 1 space after closing parenthesis; found 0
Open

if(isset($_SESSION['sessionID'])){
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Expected 1 space after closing parenthesis; found 0
Open

        } elseif($public_page){
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Expected 1 space after IF keyword; 0 found
Open

        if($active_page){
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Expected 1 space after closing parenthesis; found 0
Open

        if($active_page){
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Expected 1 space after ELSE keyword; 0 found
Open

    } else{
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Expected 1 space after ELSE keyword; 0 found
Open

    } else{
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Expected 1 space after ELSEIF keyword; 0 found
Open

        } elseif($public_page){
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Expected 1 space after IF keyword; 0 found
Open

        if($exec_authorized){
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Expected 1 space after closing parenthesis; found 0
Open

        } elseif($active_page){
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Opening brace should be on a new line
Open

function show_login() {
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Expected 1 space after ELSEIF keyword; 0 found
Open

        } elseif($exec_page){
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Expected 1 space after closing parenthesis; found 0
Open

    } elseif($exec_page || $active_page){
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Expected 1 space after ELSEIF keyword; 0 found
Open

    } elseif($exec_page || $active_page){
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Expected 1 space after closing parenthesis; found 0
Open

    if($public_page){
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Expected 1 space after IF keyword; 0 found
Open

    if($_SESSION['sessionexec'] == 1){
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Expected 1 space after IF keyword; 0 found
Open

            if(mysqli_num_rows($result) != 0){
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Opening brace should be on a new line
Open

function show_error() {
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Expected 1 space after ELSE keyword; 0 found
Open

        } else{
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Expected 1 space after IF keyword; 0 found
Open

    if($public_page){
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Expected 1 space after closing parenthesis; found 0
Open

        if($exec_authorized){
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Expected 1 space after ELSEIF keyword; 0 found
Open

        } elseif($public_page){
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Expected 1 space after closing parenthesis; found 0
Open

        } elseif($public_page){
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Expected 1 space after closing parenthesis; found 0
Open

        } elseif($exec_page){
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Expected 1 space after ELSE keyword; 0 found
Open

} else{
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Expected 1 space after IF keyword; 0 found
Open

        if($exec_page){
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Expected 1 space after closing parenthesis; found 0
Open

            if(mysqli_num_rows($result) != 0){
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Expected 1 space after ELSE keyword; 0 found
Open

        } else{
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Expected 1 space after ELSEIF keyword; 0 found
Open

        } elseif($exec_page){
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Expected 1 space after closing parenthesis; found 0
Open

        } elseif($exec_page){
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

A closing tag is not permitted at the end of a PHP file
Open

?>
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Expected 1 space after closing parenthesis; found 0
Open

    if($_SESSION['sessionexec'] == 1){
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Opening brace should be on a new line
Open

function show_insuff_permissions() {
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Expected 1 space after ELSEIF keyword; 0 found
Open

        } elseif($active_page){
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

Expected 1 newline at end of file; 0 found
Open

?>
Severity: Minor
Found in r8conf2016/permissions.php by phpcodesniffer

There are no issues that match your filters.

Category
Status