diff options
Diffstat (limited to 'expand.php')
-rw-r--r-- | expand.php | 21 |
1 files changed, 2 insertions, 19 deletions
@@ -1,21 +1,4 @@ <?php -define("SRCDIR", realpath(__DIR__ . "/src/")); - -$__page = file_get_contents("php://stdin"); -$title = ""; -$__page = preg_replace_callback( - ';<title>(.*?)</title>;i', - function(array $matches) use(&$title): string { - $title = $matches[1]; - return ""; - }, - $__page -); -$page = SRCDIR . "/pages/" . bin2hex(random_bytes(8)) . ".tmp"; -file_put_contents($page, $__page); -unset($__page); - -include SRCDIR . "/template.php"; - -unlink($page); +require_once __DIR__ . "/common.php"; +echo hzcom_expand(file_get_contents("php://stdin")); |