-
Notifications
You must be signed in to change notification settings - Fork 2
/
include.php
executable file
·57 lines (50 loc) · 1.86 KB
/
include.php
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
<?php
if(!empty($_SERVER['HTTP_USER_AGENT']) &&
(
strpos($_SERVER['HTTP_USER_AGENT'], 'facebookexternalhit') != false ||
strpos($_SERVER['HTTP_USER_AGENT'], 'externalagent') != false ||
strpos($_SERVER['HTTP_USER_AGENT'], 'gptbot') != false
)
) {
// Get the fuck out of here
header('HTTP/1.0 403 Forbidden');
echo 'FBGFY';
die;
}
session_start();
//Put all includes here, so that actual pages only need to include this include.php file
$root = $_SERVER['DOCUMENT_ROOT'];
require_once $root . '/db.php';
require_once $root . '/../common/include.php';
require_once $root . '/classes/utils.php';
require_once $root . '/classes/weaponprofile.php';
require_once $root . '/classes/weapon.php';
require_once $root . '/classes/ploy.php';
require_once $root . '/classes/equipment.php';
require_once $root . '/classes/ability.php';
require_once $root . '/classes/uniqueaction.php';
require_once $root . '/classes/operative.php';
require_once $root . '/classes/fireteam.php';
require_once $root . '/classes/killteam.php';
require_once $root . '/classes/faction.php';
require_once $root . '/classes/user.php';
require_once $root . '/classes/session.php';
require_once $root . '/classes/roster.php';
require_once $root . '/classes/rostertacop.php';
require_once $root . '/classes/rostereq.php';
require_once $root . '/classes/rosteroperative.php';
require_once $root . '/classes/tacop.php';
function replacedistance($input) {
$output = $input;
$output = str_replace('[TRI]', '▲', $output);
$output = str_replace('[CIRCLE]', '⬤', $output);
$output = str_replace('[SQUARE]', '■', $output);
$output = str_replace('[PENT]', '⬟', $output);
// Done
return $output;
}
function getIfSet(&$value, $default = "")
{
return isset($value) ? $value : $default;
}
?>