-
Notifications
You must be signed in to change notification settings - Fork 525
/
credits.php
28 lines (23 loc) · 685 Bytes
/
credits.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
<?php
$_SERVER['BASE_PAGE'] = 'credits.php';
include_once __DIR__ . '/include/prepend.inc';
// Put credits information to $credits
ob_start();
phpcredits();
$credits = ob_get_clean();
// Strip all but the body and drop styles
preg_match('!<body.*?>(.*)</body>!ims', $credits, $m);
$credits = preg_replace('!<style.*?>.*</style>!ims', '', $m[1]);
// Fix for PHP bug #24839,
// which affects the page layout
$credits = str_replace(
["</center>", "& "],
["</div>", "& "],
$credits,
);
// If there is something left, print it out
if ($credits) {
site_header("Credits", ["current" => "community", 'css' => ['credits.css']]);
echo $credits;
site_footer();
}