Bookify söker ny ägare och kommer stängas ner under 2026. Intresserad av att driva Bookify vidare? Hör av dig till kontakt[at]bookify.se
include "../data/scripts/connect.php";
include "../data/scripts/functions.php";
$time = microtime();
$time = explode(' ', $time);
$time = $time[1] + $time[0];
$start = $time;
/*
$table_id = table_id($conn);
$nr_of_res = mysqli_query($conn,"SELECT MATCH(title, isbn, author) AGAINST ('$search_string') AS score from allproducts".$table_id." WHERE MATCH (title, isbn, author) AGAINST('$search_string') LIMIT 225");
$nr_of_res = mysqli_num_rows($nr_of_res);
*/
$page_rows = 25;
$max_matches =225;
if (!empty($_GET['page'])) {
$pagenum = intval($_GET['page']);
if (empty($pagenum) || $pagenum < 1) {$pagenum = 1;}
$currentOffset = ($pagenum -1)* $page_rows;
if ($currentOffset > ($max_matches-$page_rows) ) {
$pagenum = 9;
}
} else {
$pagenum = 1;
$currentOffset = 0;
}
include('../data/scripts/sphinxapi.php');
$s = new SphinxClient;
$s->setServer("127.0.0.1", 9312);
$s->SetLimits($currentOffset,$page_rows);
$s->setMatchMode(SPH_MATCH_EXTENDED2);
$s->SetSortMode(SPH_SORT_EXTENDED, $order_by);
$result = $s->Query($search_string);
$nr_of_res = $result['total'];
$nr_of_pages = ceil($result['total']/$page_rows);
if($nr_of_res > 225){
$nr_of_res = 225;
$nr_of_pages = 9;
}
/*
if($nr_of_res==225){
$nr_of_pages = 9;
}
else{
$nr_of_pages = ceil($nr_of_res/$page_rows);
}
if (!(isset($_GET['page'])))
{
$pagenum = 1;
}
if(isset($_GET['page']))
{
$page_get = $_GET['page'];
if ($page_get < 1)
{
$pagenum = 1;
}
else if ($page_get > $nr_of_pages)
{
$pagenum = $nr_of_pages;
}
else {
$pagenum = $page_get;
}
}
$limit_res = ($pagenum - 1) * $page_rows .',' .$page_rows;
*/
if($search_string == ""){
$nr_of_res = 0;
}
//$nr_of_res = 1; //om localhost
if($nr_of_res > 0){
$ids = array_keys($result['matches']); //om servern
$query = mysqli_query($conn, "select * from allproducts where isbn in(".implode(',',$ids).")"); //om servern
//$query = mysqli_query($conn, "select * from allproducts where isbn = ".$search_string.""); //om localhost
$res_this_page = mysqli_num_rows($query);
$rows = array();
//om servern
while ($row = mysqli_fetch_array($query)) {
$rows[$row['isbn']] = $row;
}
$ordered_rows = array();
foreach($ids as $index) {
$id_float = explode(".", $index);
$index = $id_float[0];
$ordered_rows[$index] = $rows[$index];
}
//om servern
}
$time = microtime();
$time = explode(' ', $time);
$time = $time[1] + $time[0];
$finish = $time;
$total_time = round(($finish - $start), 4);
//echo 'Sökningen tog '.$total_time.' sekunder.';
$result = mysqli_query($conn,"INSERT INTO search_log (query_time) values ('$total_time')");
function pagination_url($i){
$params = $_GET;
$params['page'] = $i;
$paramString = http_build_query($params);
echo "?".$paramString;
}
$pageID="compare-books";
include "../data/scripts/header-tag.php";
?>
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
Combat Techniques of Tai Ji, Xing Yi, and BA Gua (Häftad)
ISBN: 9781583941454 - UTGIVEN:
2006-02
The combat techniques of Tai Ji, Ba Gua, and Xing Yi were forbidden during China's Cultural Revolution, but the teachings of grandmaster Wang Pei Shing have survived. This comprehensive guide, written by one of his students, selects core movements from each practice and gives the student powerful to[...]
Optimal Parenting (Häftad)
av Ba Luvmour
ISBN: 9781591810414 - UTGIVEN:
200603
This book shows you how to use Natural Learning Rhythms -- a comprehensive thoroughly-researched, easy-to-understand system of child development and family dynamics -- to create environments for optimal well-being. This parenting approach addresses the emotional, physical, and spiritual development[...]
-
-
De (Inbunden)
av Gabriel Ba
ISBN: 9781595825575 - UTGIVEN:
201010
From the company that introduced American audiences to Brazilian twins Fabio Moon and Gabriel Ba ("Daytripper", "Pixu") comes a new hardcover edition of Dark Horse's out-of-print "De:Tales", a collection of the twins' breakthrough short stories! After three Eisner Awards and a series of acclaimed pr[...]