forked from php/web-php
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcredits.php
More file actions
30 lines (25 loc) · 726 Bytes
/
credits.php
File metadata and controls
30 lines (25 loc) · 726 Bytes
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
<?php
$_SERVER['BASE_PAGE'] = 'credits.php';
include_once __DIR__ . '/include/prepend.inc';
// Put credits information to $credits
ob_start();
phpcredits();
$credits = ob_get_contents();
ob_end_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(
array("</center>", "& "),
array("</div>", "& "),
$credits
);
// If there is something left, print it out
if ($credits) {
site_header("Credits", array("current" => "community", 'css' => array('credits.css')));
echo $credits;
site_footer();
}
?>