Completed
Pull Request — develop (#51)
by Patrick
02:44
created

delete.php (1 issue)

Severity

Upgrade to new PHP Analysis Engine

These results are based on our legacy PHP analysis, consider migrating to our new PHP analysis engine instead. Learn more

1
<?php
2
ini_set('display_errors', 1);
3
error_reporting(E_ALL);
4
//Redirect users to https
5 View Code Duplication
if($_SERVER["HTTPS"] != "on")
6
{
7
    header("Location: https://".$_SERVER["HTTP_HOST"].$_SERVER["REQUEST_URI"]);
8
    exit();
9
}
10
require_once("class.FlipSession.php");
11
if(!FlipSession::isLoggedIn())
12
{
13
    header("Location: login.php");
14
    exit();
15
}
16
require_once('class.ProfilesPage.php');
17
$page = new ProfilesPage('Burning Flipside Profiles');
18
19
//Page specific JS
20
$page->addJSByURI('js/delete.js');
21
22
$page->body = '
23
<div id="content">
24
    <div class="alert alert-danger" role="alert">
25
        <table>
26
            <tr>
27
                <td>
28
                    <span class="fa fa-fire" style="font-size: 5em;"></span>
29
                </td>
30
                <td>
31
        Please note: This operation is <strong>irreversible</strong>! Once your account is deleted you will no longer have access to 
32
        any of your ticket requests, theme camp registrations, art proejct registrations or other information you have provided to AAR,
33
        LLC.
34
                </td>
35
            <tr>
36
        </table>
37
    </div>
38
    <input type="checkbox" onclick="allow_delete()">Yes, I understand that this operation is irreversible. Please delete my account.</input><br/><br/><br/>
39
    <button type="button" class="btn btn-danger" disabled>Delete My Account</button> 
40
</div>';
41
42
$page->printPage();
43
/* vim: set tabstop=4 shiftwidth=4 expandtab:*/
44
?>
0 ignored issues
show
It is not recommended to use PHP's closing tag ?> in files other than templates.

Using a closing tag in PHP files that only contain PHP code is not recommended as you might accidentally add whitespace after the closing tag which would then be output by PHP. This can cause severe problems, for example headers cannot be sent anymore.

A simple precaution is to leave off the closing tag as it is not required, and it also has no negative effects whatsoever.

Loading history...
45