-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex.php
More file actions
68 lines (60 loc) · 3.5 KB
/
Copy pathindex.php
File metadata and controls
68 lines (60 loc) · 3.5 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
<?php
ini_set('display_errors', '1');
ini_set('display_startup_errors', '1');
error_reporting(E_ALL);
require_once 'pages/classes.php';
// Start session
session_start();
if (!isset($_SESSION['step']))
$_SESSION['step'] = 0;
$page = new $STEPS[$_SESSION['step']];
?>
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>OpenMMA Installer</title>
<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0-alpha1/dist/js/bootstrap.bundle.min.js" integrity="sha384-w76AqPfDkMBDXo30jS1Sgez6pr3x5MlQ1ZAGC+nuZB+EYdgRZgiwxhTBTkF7CXvN" crossorigin="anonymous"></script>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.6.3/jquery.min.js"></script>
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.3.0/css/all.min.css" integrity="sha512-SzlrxWUlpfuzQ+pcUCosxcglQRNAq/DZjVsC0lE40xsADsfeQoEypE+enwcOiGjk/bSuGGKHEyjSoQ1zVisanQ==" crossorigin="anonymous" referrerpolicy="no-referrer" />
<link href="css/bootstrap-openmma.min.css" rel="stylesheet">
<script>
function submit() {
$.post('ajax/', {}).done((data) => {
data = JSON.parse(data);
switch (data.status) {
case 'success':
location.reload();
break;
default:
alert('Error: ' + data.status);
}
});
}
</script>
</head>
<body class="d-flex flex-column vh-100 overflow-hidden">
<nav class="navbar bg-body-secondary border-bottom px-3">
<a class="navbar-brand fs-3" href="/">
<svg class="d-inline-block align-text-top me-2" id="logo-39" width="50" height="40" viewBox="0 0 50 40" fill="none" xmlns="http://www.w3.org/2000/svg"> <path d="M25.0001 0L50 15.0098V24.9863L25.0001 40L0 24.9863V15.0099L25.0001 0Z" fill="#A5B4FC" class="ccompli2"></path> <path fill-rule="evenodd" clip-rule="evenodd" d="M0 15.0098L25 0L50 15.0098V24.9863L25 40L0 24.9863V15.0098ZM25 33.631L44.6967 21.8022V18.1951L44.6957 18.1945L25 30.0197L5.30426 18.1945L5.3033 18.1951V21.8022L25 33.631ZM25 24.5046L40.1018 15.4376L36.4229 13.2298L25 20.0881L13.5771 13.2298L9.89822 15.4376L25 24.5046ZM25 14.573L31.829 10.4729L25 6.37467L18.171 10.4729L25 14.573Z" fill="#4F46E5" class="ccustom"></path> <path d="M25.0001 0L0 15.0099V24.9863L25 40L25.0001 0Z" fill="#A5B4FC" class="ccompli2" fill-opacity="0.3"></path> </svg>
OpenMMA Installer
</a>
</nav>
<div class="d-flex justify-content-center align-items-center" style="min-height: 100%;
background: url(img/polygons.png);
background-size: cover;">
<div class="card shadow m-4 border-0 flex-grow-1" style="max-width: 500px;">
<div class="card-header text-center border-0 fs-4">
<?php echo $page->title(); ?>
</div>
<div class="card-body">
<?php echo $page->render(); ?>
<div class="d-grid">
<button class="btn btn-primary" onclick="submit()"><?php echo $page->submit_label(); ?></button>
</div>
</div>
</div>
</div>
</body>
</html>