From 3d8273c020cf42052f135fca9dcefeb8160e69fc Mon Sep 17 00:00:00 2001 From: Gabor Hojtsy Date: Mon, 28 Jul 2003 09:25:51 +0000 Subject: [PATCH] Reformatting, adding comments, and support for base href. --- credits.php | 42 +++++++++++++++++++++++++----------------- 1 file changed, 25 insertions(+), 17 deletions(-) diff --git a/credits.php b/credits.php index 6f90f8fa4..cc8d5b22b 100644 --- a/credits.php +++ b/credits.php @@ -1,26 +1,34 @@ (.*)<\/body>/ims', $credits, $m); + // Strip all but the body + preg_match('!(.*)!ims', $credits, $m); - // strip out any style - $credits = preg_replace('/.*<\/style>/ims', '', $m[1]); + // Strip out any style + $credits = preg_replace('!.*!ims', '', $m[1]); - if ($credits) { - commonHeader("PHP Credits", 1); - echo $credits; - commonFooter(); - exit; - } + // If there is something left, print it out + if ($credits) { + commonHeader("Credits"); + echo $credits; + commonFooter(); + } +} + +// No output buffer support, standard credits page +else { + phpcredits(); } -phpcredits(); - ?>