From f23c2ec77702a44858794980372e39d4ac636bb1 Mon Sep 17 00:00:00 2001 From: Andrey Kuvshinov Date: Fri, 15 May 2020 22:02:08 +0300 Subject: [PATCH] test book cookie --- app/routes/anpdf.php | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/app/routes/anpdf.php b/app/routes/anpdf.php index 295e07d..f45f578 100644 --- a/app/routes/anpdf.php +++ b/app/routes/anpdf.php @@ -139,6 +139,7 @@ function bookmark_get($hash){ $bookcook = 'book_'.$hash; if (isset($_COOKIE[$bookcook])) + echo $_COOKIE[$bookcook]; return $_COOKIE[$bookcook]; else return false; @@ -187,11 +188,10 @@ function promo_kuri($hash, $page = 0, $promo = true){ $bookmark = bookmark_get($hash); $page = 1; //если нет страницы то первая if ($bookmark !== false and $bookmark > 1){ - $redurl = SITE.'read/'.$hash.'/'.$bookmark.'/'.$promo; - echo $redurl; - // header("HTTP/1.1 301 Moved Permanently"); - // header('Location: '.SITE.'read/'.$hash.'/'.$bookmark.'/'.$promo); - // exit(); + $redurl = SITE.'read/'.$hash.'/'.$bookmark.'/'.$promo; + header("HTTP/1.1 301 Moved Permanently"); + header('Location: '. $redurl); + exit(); } }