add promo
This commit is contained in:
@@ -27,7 +27,10 @@ function anpromo_kuri($page = 1, $scale = 2){
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
function read_kuri($hash, $page = 1, $scale = 2){
|
|
||||||
|
|
||||||
|
|
||||||
|
function read_kuri($hash, $page = 1, $scale = 2, $promo = false){
|
||||||
|
|
||||||
$price = db_get("SELECT `price_id`, `pricename` FROM `price` WHERE `pricehash` = '$hash' LIMIT 1");
|
$price = db_get("SELECT `price_id`, `pricename` FROM `price` WHERE `pricehash` = '$hash' LIMIT 1");
|
||||||
|
|
||||||
@@ -41,7 +44,45 @@ function read_kuri($hash, $page = 1, $scale = 2){
|
|||||||
$pdfile = "/file/$hash";
|
$pdfile = "/file/$hash";
|
||||||
$maxpage = 32;
|
$maxpage = 32;
|
||||||
$title = $price['pricename'];
|
$title = $price['pricename'];
|
||||||
$filedown = True;
|
|
||||||
|
if (!$promo)
|
||||||
|
$filedown = True;
|
||||||
|
|
||||||
|
$baseurl = "/read/$hash/";
|
||||||
|
|
||||||
|
if ($page < $maxpage){
|
||||||
|
$nextpage = $page + 1;
|
||||||
|
$nexturl = "$baseurl$nextpage";
|
||||||
|
}
|
||||||
|
|
||||||
|
if ($page > 1) {
|
||||||
|
$prevpage = $page - 1;
|
||||||
|
$prevurl = "$baseurl$prevpage";
|
||||||
|
}
|
||||||
|
|
||||||
|
include ('anpdf.phtml');
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
function promo_kuri($hash, $page = 1, $scale = 2, $promo = false){
|
||||||
|
|
||||||
|
$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'];
|
||||||
|
$pdfile = "/file/$hash";
|
||||||
|
$maxpage = 32;
|
||||||
|
$title = $price['pricename'];
|
||||||
|
|
||||||
|
if (!$promo)
|
||||||
|
$filedown = False;
|
||||||
|
|
||||||
$baseurl = "/read/$hash/";
|
$baseurl = "/read/$hash/";
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user