query("SET NAMES 'utf8'"); $query = 'SELECT * FROM `x_arenda` ORDER BY dir' or die("Error in the consult.." . mysqli_error($link)); $res_i = mysqli_query($link, $query); while($rom=mysqli_fetch_array($res_i)) { if($rom["tip_en"]!=$tip) echo "

" . $rom["tip_en"] . "

"; echo "

" . $rom["ttl_en"] . "

"; if($rom["xpl_en"]!="") echo $rom["xpl_en"] . "
"; if($rom["y"]!="") echo $rom["y"] . "
"; if($rom["ves_en"]!="") echo "load capacity: " . $rom["ves_en"] . "
"; if($rom["x_en"]!="") echo $rom["x_en"] . "
"; if($rom["h"]!="") echo "price: " . $rom["h"] . " rubles/hour
"; if($rom["d"]!="") echo "price: " . $rom["d"] . " rubles/24 hours
"; if($rom["adr_en"]!="") echo "

Address: " . $rom["adr_en"] . "
"; echo "Renting documents are provided.
"; $img = "images/" . $rom["dir"] . "/" . $rom["img"] . "_0.jpg"; if (file_exists($img)) echo "

" . $rom["ttl_en"] . ", " . $rom["xpl_en"] . "
"; echo "
"; $tip = $rom["tip_en"]; } mysqli_free_result($res_i); include('inc/footer.php'); ?>