Remove print page

It is pointless nowadays.
This commit is contained in:
2022-01-13 02:51:32 +01:00
parent 91acce61ef
commit caaf36b170
3 changed files with 2 additions and 26 deletions

View File

@@ -1,7 +1,7 @@
RewriteEngine on
RewriteCond &%{QUERY_STRING} &page=([^&]+) [NC]
RewriteRule ^(maincg\.php)?$ %1.html [R=301,QSD,L]
RewriteRule ^((maincg|printcg)\.php)?$ %1.html [R=301,QSD,L]
RewriteRule pages/(.*)\.php $1.html [R=301,L]

View File

@@ -1,2 +1,2 @@
<a href="http://www.tojnar.cz/krk/mainkrk.php" target="_blank">Web&nbsp;KRK</a>
&brvbar;<a href="http://www.tojnar.cz/krk/mainkrk.php?page=mcr_2009/mcr_2009" target="_blank">MČR&nbsp;v&nbsp;rogainingu</a> &brvbar;<a href="/printcg.php?page=<?= $page; ?>" target="_blank">Verze&nbsp;pro&nbsp;tisk</a>
&brvbar;<a href="http://www.tojnar.cz/krk/mainkrk.php?page=mcr_2009/mcr_2009" target="_blank">MČR&nbsp;v&nbsp;rogainingu</a>

View File

@@ -1,24 +0,0 @@
<?php
$page = $_GET['page'] ?? 'cyklogaining';
?>
<!doctype html public "-//W3C//DTD HTML 4.01//EN">
<html>
<head>
<meta http-equiv="Content-type" content="text/html; charset=utf-8">
<link rel="stylesheet" href="/print.css" type="text/css">
<link type="image/png" href="/images/logo_krk16.png" rel="shortcut icon">
<title>Tisk</title>
</head>
<body>
<div class="main">
<?php
$escaped_page = str_replace([')', '(', '\\', '"', "\'", ';', '{', '}', '$', '[', ']', '<', '>'], '', $page);
if (file_exists("pages/$escaped_page.php")) {
include "./pages/$escaped_page.php";
} else {
include './pages/404.php';
}
?>
</div>
</body>
</html>