config["head"]["cur_path"]=""; $site->params["only_active"]="Y"; $site->config["pref_def"]["fplace"]=array("type"=>"int"); $site->config["pref_def"]["fcountry"]=array("type"=>"int"); $site->config["pref_def"]["fregion"]=array("type"=>"int"); $site->config["pref_def"]["fcity"]=array("type"=>"int"); $site->config["pref_def"]["fdistrict"]=array("type"=>"int"); $site->config["pref_def"]["fokrug"]=array("type"=>"int"); $site->config["pref_def"]["search_r"]=array("type"=>"string"); $site->config["pref_def"]["family"]=array("type"=>"string"); $site->config["pref_def"]["name"]=array("type"=>"string"); $site->config["pref_def"]["company_name"]=array("type"=>"string"); $site->config["pref_def"]["pager_count"]=array("type"=>"string"); $site->params_get(); $site->out_url(); $SETTINGS["PAGER_TYPE"]=3; $SETTINGS["PAGER_COUNT_OBJ_ON_PAGE"]=0; if($site->params['search_r']=='Y'){ $where=""; if($site->params['fcountry']!=""){ if($where!="") $where.=" and "; $where.=" country=".$site->params['fcountry']; } if($site->params['fregion']!=""){ if($where!="") $where.=" and "; $where.=" region=".$site->params['fregion']; } if($site->params['fcity']!=""){ if($where!="") $where.=" and "; $where.=" city=".$site->params['fcity']; } if($site->params['fokrug']!=""){ if($where!="") $where.=" and "; $where.=" okrug=".$site->params['fokrug']; } if($site->params['fdistrict']!=""){ if($where!="") $where.=" and "; $where.=" district=".$site->params['fdistrict']; } if($where!="") $where.=" and "; $where.=" members like 'u%' "; if($where!="") $where.=" and "; $where.=" active='Y' "; /* if($site->params['type_show']=="f"){ if($where!="") $where.=" and "; $where.=" members like 'f%' "; } */ if($where!="") $where=" where ".$where; $sql1="select distinct(members), count(id) as count_r from realty "; $sql2="select distinct(members),count(id) as count_c from commercial "; if($where!=""){ $sql1.=$where; $sql2.=$where; } $sql1.=" group by members order by count_r desc"; $sql2.=" group by members order by count_c desc"; $res1=sql_execute($sql1,"",$StLimit,$SETTINGS["PAGER_COUNT_OBJ_ON_PAGE"]); $res2=sql_execute($sql2,"",$StLimit,$SETTINGS["PAGER_COUNT_OBJ_ON_PAGE"]); $site->params["show_pager"]=$SETTINGS["pager_show_pager"]; $site->params["show_realty"]=$res1; $site->params["show_commercial"]=$res2; $SETTINGS['part_name']="Результаты поиска"; $SETTINGS['navigator']=array("/"=>"Главная","/search_members.php"=>"Поиск риэлтора",""=>$SETTINGS['part_name']); }else{ $site->params["no_ex_data"] = true; $site->show_search(); $SETTINGS['part_name']="Поиск риэлтора"; $SETTINGS['navigator']=array("/"=>"Главная",""=>$SETTINGS['part_name']); } $SETTINGS["title_ex"]="Поиск риэлтора в странах СНГ"; $SETTINGS["description_ex"]="Поиск риэлтора в странах снг"; $SETTINGS["keywords_ex"]="поиск риэлтора, найти риэлтора, недвижимость страны СНГ"; $SETTINGS['kur_page']='search_members'; include $SETTINGS["PATH_HTML"]."/top.html"; if($site->params['search_r']=='Y'){ include $SETTINGS["PATH_HTML"]."/result_search_member.html"; }else{ include $SETTINGS["PATH_HTML"]."/search_member.html"; } include $SETTINGS["PATH_HTML"]."/bottom.html"; debug_echo(); ?>