Array( 'no_elements'=>'Извините, в данный момент элементов нет!', 'more'=>'Подробнее...' ), # Английский 'en'=>Array( 'no_elements'=>'Sorry, no elements found!', 'more'=>'More...' ) ); require($_SERVER["DOCUMENT_ROOT"]."/incom/template/header.php"); if (isset($_GET['id']) AND (intval($_GET['id']) != '') && (mysql_num_rows(mysql_query("SELECT 'id' FROM `i_block_elements` WHERE `version`='$lang' AND `id`='".intval($_GET['id'])."'")) == 1)) { $element_id = intval($_GET['id']); $sql_query = "SELECT * FROM `i_block_elements` WHERE `version`='$lang' AND `id`='$element_id' LIMIT 1"; # Выполняем запрос $get_element = mysql_query($sql_query); if (mysql_num_rows($get_element) == 1) { $row = mysql_fetch_assoc($get_element); ?>

0) { while($r = mysql_fetch_array($s)) { $ids[]=$r["id"]; $ss = mysql_query("SELECT * FROM i_block WHERE id_section='".$r["id"]."'"); if (mysql_num_rows($ss)>0) { while($rr = mysql_fetch_array($ss)) { $ids[]=$rr["id"]; } } } } $sql = "`id_section` in (".join(',',$ids).") AND "; } else if (isset($_GET["new"])) $sql = "`cat_nov`='1' AND "; else if (isset($_GET["spec"])) $sql = "`cat_spec`='1' AND "; $api->Pages->setvars($lang, $_SERVER['PHP_SELF'], $_SERVER['QUERY_STRING'], mysql_result(mysql_query("SELECT COUNT('id') FROM `i_block_elements` WHERE ".$sql."`version`='$lang' "), 0), $per_page, @$_GET['p']); if (!empty($_GET['p'])) {$start=$_GET['p'];} else {$start=1; $_GET["p"]=1;} $sql_query = "SELECT * FROM `i_block_elements` WHERE ".$sql."`version`='$lang' ORDER BY cat_sort ASC LIMIT ".$api->Pages->start_from.", $per_page"; $get_elements = mysql_query($sql_query); if (mysql_num_rows($get_elements) != 0) { $i=1; echo '
'; echo $api->Pages->pages_gen(); } else { echo '


'.$mod_lang_mass["$lang"]['no_elements'].'





'; } } require($_SERVER["DOCUMENT_ROOT"]."/incom/template/footer.php"); ?>