2020-04-01 17:51:22 +03:00
|
|
|
<?php
|
|
|
|
|
|
|
|
|
|
|
2020-04-07 19:19:31 +03:00
|
|
|
ini_set('display_errors','off');
|
|
|
|
|
error_reporting(E_ALL);
|
|
|
|
|
|
2020-04-02 10:13:29 +00:00
|
|
|
function anpromo_kuri($page = 1, $scale = 2){
|
2020-04-01 17:51:22 +03:00
|
|
|
|
|
|
|
|
// $pdfile = 'https://argumenti.ru/templinks/md5files/f9598f88e667146d50d106eeedbd74c1.pdf';
|
2020-04-01 21:26:25 +03:00
|
|
|
$pdfile = '/pub/files/promo.pdf';
|
2020-04-01 17:51:22 +03:00
|
|
|
$maxpage = 32;
|
2020-04-02 08:53:50 +00:00
|
|
|
$title = 'Номер 12(706)';
|
2020-04-01 17:51:22 +03:00
|
|
|
|
|
|
|
|
if ($page < $maxpage){
|
|
|
|
|
$nextpage = $page + 1;
|
|
|
|
|
$nexturl = "/anpromo/$nextpage";
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
if ($page > 1) {
|
|
|
|
|
$prevpage = $page - 1;
|
|
|
|
|
$prevurl = "/anpromo/$prevpage";
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
include ('anpdf.phtml');
|
|
|
|
|
|
2020-04-07 19:09:45 +03:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
2020-04-07 19:26:01 +03:00
|
|
|
function read_kuri($hash, $page=1){
|
2020-04-07 19:09:45 +03:00
|
|
|
|
|
|
|
|
$price = db_get("SELECT `price_id`, `pricename` FROM `price` WHERE `pricehash` = '$hash' LIMIT 1");
|
|
|
|
|
|
|
|
|
|
if (!isset($price['price_id'])){
|
|
|
|
|
header("HTTP/1.0 404 Not Found");
|
|
|
|
|
echo "file not found";
|
|
|
|
|
return False;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
$id = $price['price_id'];
|
2020-04-07 19:27:21 +03:00
|
|
|
$pdfile = "/file/$hash";
|
2020-04-07 19:09:45 +03:00
|
|
|
$maxpage = 32;
|
|
|
|
|
$title = $price['pricename'];
|
|
|
|
|
$filedown = True;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if ($page < $maxpage){
|
|
|
|
|
$nextpage = $page + 1;
|
|
|
|
|
$nexturl = "/anpromo/$nextpage";
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
if ($page > 1) {
|
|
|
|
|
$prevpage = $page - 1;
|
|
|
|
|
$prevurl = "/anpromo/$prevpage";
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
include ('anpdf.phtml');
|
|
|
|
|
|
|
|
|
|
|
2020-04-01 17:51:22 +03:00
|
|
|
}
|