$uri_keys[$get_key]["db"] ); $explode = explode("_", $uri_array["param_2"]); $product["id"] = intval($explode[sizeof($explode)-1]); if($product["id"] > 0) { // Product $sql = " SELECT products.id AS id, products.item_number AS item_number, products.name AS name, products.count AS count, products.keywords AS keywords, products.text_short AS text_short, products.text_long AS text_long, products.text_long_2 AS text_long_2, products.time AS time, products.price AS price_net, products.afa AS vat, products.akcio_fix AS akcio_fix, products.akcio_percent AS akcio_percent, products_images.original AS image FROM products LEFT JOIN products_images ON products_images.product_time = products.time AND products_images.type = 'main' WHERE products.id = '" . $product["id"] . "' GROUP BY products.id "; // print sqlcode($sql); $mysql_query = mysqli_query($connect[$product["database"]], $sql); while($line = mysqli_fetch_array($mysql_query)) { $isset = 1; $product["id"] = $line["id"]; $product["item_number"] = $line["item_number"]; $product["time"] = $line["time"]; $product["name"] = $line["name"]; $product["count"] = $line["count"]; $product["keywords"] = $line["keywords"]; $product["text_short"] = $line["text_short"]; $product["text_long"] = $line["text_long"]; $product["text_long_2"] = $line["text_long_2"]; $product["url"] = $settings["href"] . "termek/" . $get_key . "/" . generate_url($product["name"]) . "_" . $product["id"] . "/"; $product["image"] = $line["image"]; $product["price_net"] = $line["price_net"]; $product["price_vat"] = $line["vat"]; $product["akcio_fix"] = $line["akcio_fix"]; $product["akcio_percent"] = $line["akcio_percent"]; $product["out_href"] = $uri_keys[$get_key]["url"]; } $product["out_href"] .= "termek/" . $product["id"] . "-" . generate_url($product["name"]); if($isset == 1) { // Meta $meta["title"] = $product["name"]; $meta["keywords"] = $product["keywords"]; $meta["description"] = $product["text_short"]; $location = array(); // Category $sql = "SELECT category_id FROM products_category WHERE product_time = '" . $product["time"] . "' LIMIT 0,1"; $mysql_query = mysqli_query($connect[$product["database"]], $sql); while($line = mysqli_fetch_array($mysql_query)) { $product["category_id"] = $line["category_id"]; $sql_sub = "SELECT id, name, main FROM categories_sub WHERE id = '" . $line["category_id"] . "'"; $mysql_query_sub = mysqli_query($connect[$product["database"]], $sql_sub); while($line_sub = mysqli_fetch_array($mysql_query_sub)) { $sql_middle = "SELECT id, name, main FROM categories_middle WHERE id = '" . $line_sub["main"] . "'"; $mysql_query_middle = mysqli_query($connect[$product["database"]], $sql_middle); while($line_middle = mysqli_fetch_array($mysql_query_middle)) { if($get_key != "csomagtarto") { $sql_main = "SELECT id, name, main FROM categories_main WHERE id = '" . $line_middle["main"] . "'"; $mysql_query_main = mysqli_query($connect[$product["database"]], $sql_main); while($line_main = mysqli_fetch_array($mysql_query_main)) { $data = array( "url" => $settings["href"] . "termekek/" . $get_key . "/" . generate_url($line_main["name"]) . "_1" . $line_main["id"] . "/", "label" => $line_main["name"] ); array_push($location, $data); unset($data); } } $data = array( "url" => $settings["href"] . "termekek/" . $get_key . "/" . generate_url($line_middle["name"]) . "_2" . $line_middle["id"] . "/", "label" => $line_middle["name"] ); array_push($location, $data); unset($data); } if($get_key != "e-csomagtarto") { $data = array( "url" => $settings["href"] . "termekek/" . $get_key . "/" . generate_url($line_sub["name"]) . "_3" . $line_sub["id"] . "/", "label" => $line_sub["name"] ); array_push($location, $data); unset($data); } } } $data = array( "url" => $product["url"], "label" => $product["name"] ); array_push($location, $data); unset($data); // Image if($product["image"] == "") { $product["image"] = $settings["href"] . "public/lib/img/noimage.png"; } elseif(substr($product["image"], 0, 4) != "http") { $product["image"] = $uri_keys[$get_key]["url"] . "temp/products/" . $product["image"]; } // Price $product["price_gross"] = $product["price_net"] + round($product["price_net"] * $product["price_vat"] / 100); // On sale if($product["akcio_fix"] > 0) { $product["price_sale"] = $product["akcio_fix"] + round($product["akcio_fix"] * $product["price_vat"] / 100); $product["price_sale_net"] = $product["akcio_fix"]; } elseif($product["akcio_percent"] > 0) { $product["price_sale"] = $product["price_gross"] - round($product["price_gross"] * $product["akcio_percent"] / 100); $product["price_sale_net"] = $product["price_gross"] - round($product["price_gross"] * $product["price_vat"] / 100); } // print "
";
			// print_r($product);
			// print "
"; } else { $error_msg = "Nem létező termék."; } } else { $error_msg = "Nem létező termék."; } } else { $error_msg = "Nem létező termék."; } ?> $line["autokatt"], "menabocs" => $line["menabocs"], "bikihu" => $line["bikihu"], "ecsomag" => $line["ecsomag"] ); } $sql = "SELECT logo FROM settings WHERE id = 1"; $mysql_query = mysqli_query($connect["allehu"], $sql); while($line = mysqli_fetch_array($mysql_query)) { $logo = "../public/temp/logo/" . $line["logo"]; } ?> <?= $meta["title"] ?> " /> " /> " />
0)) { ?>
">

')">  

0) { ?> Ft Ft ( Ft + ÁFA) Ft ( Ft + ÁFA)
0) { $m = $product["price_gross"] - $product["price_sale"]; ?>
Megtakarítás:
Ft
Cikkszám:
Elérhetőség:
0) { print "Készleten"; } else { print "Nincs készleten"; } ?>
'" />
" />
" /> " />
 

", "", $product["text_long_2"]); print $product["text_long_2"]; ?>
Hasonló termékek
$line["id"], "name" => $line["name"], "price_net" => $line["price_net"], "price_vat" => $line["vat"], "price_gross" => 0, "image" => $line["image"], "akcio_fix" => $line["akcio_fix"], "akcio_percent" => $line["akcio_percent"], "price_sale" => 0, "href" => "" ); // Image if($data["image"] == "") { $data["image"] = $settings["href"] . "public/lib/img/noimage.png"; } elseif(substr($data["image"], 0, 4) != "http") { $data["image"] = $uri_keys[$get_key]["url"] . "temp/products/" . $data["image"]; } // Price $data["price_gross"] = $data["price_net"] + round($data["price_net"] * $data["price_vat"] / 100); // On sale if($data["akcio_fix"] > 0) { $data["price_sale"] = $data["akcio_fix"] + round($data["akcio_fix"] * $data["price_vat"] / 100); } elseif($data["akcio_percent"] > 0) { $data["price_sale"] = $data["price_gross"] - round($data["price_gross"] * $data["akcio_percent"] / 100); } // HREF $data["href"] = $settings["href"] . "termek/" . $get_key . "/" . generate_url($data["name"]) . "_" . $data["id"] . "/"; array_push($render_products, $data); unset($data); } ?>