query($sql); $aux = mysql_fetch_assoc($result); $category_id = $aux['category_id']; } */ // Category auxiliar code -------------------- if ($category_id) { $db = db_getDBObject(); $sql = "SELECT category_id FROM ClassifiedCategorySale WHERE id = '$category_id'"; $result = $db->query($sql); $aux = mysql_fetch_assoc($result); if ($aux["category_id"] == "0"){ $sql_where_homes_sale[] = "( ClassifiedListingSale.category_id = '".$category_id."' OR ClassifiedListingSale.parent_category_id = '".$category_id."' OR ClassifiedListingSale.category_id2 = '".$category_id."' OR ClassifiedListingSale.parent_category_id2 = '".$category_id."' OR ClassifiedListingSale.category_id3 = '".$category_id."' OR ClassifiedListingSale.parent_category_id3 = '".$category_id."' )"; }else $sql_where_homes_sale[] = "ClassifiedListingSale.category_id = '".$category_id."' OR ClassifiedListingSale.category_id2 = '".$category_id."' OR ClassifiedListingSale.category_id3 = '".$category_id."'"; } // ------------------------------------------- // ID ------------------------------------ if ($id) $sql_where_homes_sale[] = "ClassifiedListingSale.id = $id"; // ------------------------------------------- // Status ------------------------------------ $sql_where_homes_sale[] = "ClassifiedListingSale.status = 'A'"; // ------------------------------------------- // Keyword ----------------------------------- if ($keyword) { $keyword = str_replace("\\", "", $keyword); $_GET["keyword"] = $keyword; // Retrieve full text minimum word length $dbObj = db_getDBObject(); $sql= "SHOW VARIABLES LIKE 'ft_min_word_len'"; $ft_min_word_len = mysql_result($dbObj->query($sql),0,1); // Check if mysql can perform full text search or not. if(is_numeric($ft_min_word_len)) { $words_arr = explode(" ",$keyword); if(count($words_arr) >= 2){ foreach($words_arr as $each_word) { if(strlen($each_word) <= $ft_min_word_len-1) { $force_text_search = true; break; } } } } /* if keyword has 3 letters or less than it */ if (strlen($keyword) <= 3) { $skeyword = Inflector::singularize($keyword); $pkeyword = Inflector::pluralize($keyword); $formated_keyword = substr(db_formatString($keyword), 1, strlen(db_formatString($keyword))-2); $formated_skeyword = substr(db_formatString($skeyword), 1, strlen(db_formatString($skeyword))-2); $formated_pkeyword = substr(db_formatString($pkeyword), 1, strlen(db_formatString($pkeyword))-2); unset($sql_aux); if($formated_keyword) { $sql_aux[] = "ClassifiedListingSale.title = '$formated_keyword'"; $sql_aux[] = "ClassifiedListingSale.title LIKE '$formated_keyword %'"; $sql_aux[] = "ClassifiedListingSale.title LIKE '% $formated_keyword'"; $sql_aux[] = "ClassifiedListingSale.title LIKE '% $formated_keyword %'"; } if($formated_skeyword) { $sql_aux[] = "ClassifiedListingSale.title = '$formated_skeyword'"; $sql_aux[] = "ClassifiedListingSale.title LIKE '$formated_skeyword %'"; $sql_aux[] = "ClassifiedListingSale.title LIKE '% $formated_skeyword'"; $sql_aux[] = "ClassifiedListingSale.title LIKE '% $formated_skeyword %'"; } if($formated_pkeyword) { $sql_aux[] = "ClassifiedListingSale.title = '$formated_pkeyword'"; $sql_aux[] = "ClassifiedListingSale.title LIKE '$formated_pkeyword %'"; $sql_aux[] = "ClassifiedListingSale.title LIKE '% $formated_pkeyword'"; $sql_aux[] = "ClassifiedListingSale.title LIKE '% $formated_pkeyword %'"; } $sql_where_homes_sale[] = "(".(implode(" OR ", $sql_aux)).")"; /* if mysql can't perform full text search with current keyword. */ } elseif($force_text_search) { $pkeyword = Inflector::pluralize($keyword); $skeyword = Inflector::singularize($keyword); $thesaurus = ($word_amount = count(explode(" ",$keyword)) == 2) ? str_replace(" ", "", $keyword) : false; $formated_keyword = substr(db_formatString($keyword), 1, strlen(db_formatString($keyword))-2); $formated_pkeyword = substr(db_formatString($pkeyword), 1, strlen(db_formatString($pkeyword))-2); $formated_skeyword = substr(db_formatString($skeyword), 1, strlen(db_formatString($skeyword))-2); $formated_thesaurus = substr(db_formatString($thesaurus), 1, strlen(db_formatString($thesaurus))-2); unset($sql_aux); if($formated_keyword) { $sql_aux[] = "ClassifiedListingSale.title LIKE '$formated_keyword%'"; $sql_aux[] = "ClassifiedListingSale.title LIKE '%$formated_keyword'"; $sql_aux[] = "ClassifiedListingSale.title LIKE '%$formated_keyword%'"; } if($formated_pkeyword) { $sql_aux[] = "ClassifiedListingSale.title LIKE '$formated_pkeyword%'"; $sql_aux[] = "ClassifiedListingSale.title LIKE '%$formated_pkeyword'"; $sql_aux[] = "ClassifiedListingSale.title LIKE '%$formated_pkeyword%'"; } if($formated_skeyword) { $sql_aux[] = "ClassifiedListingSale.title LIKE '$formated_skeyword%'"; $sql_aux[] = "ClassifiedListingSale.title LIKE '%$formated_skeyword'"; $sql_aux[] = "ClassifiedListingSale.title LIKE '%$formated_skeyword%'"; } if($formated_thesaurus) { $sql_aux[] = "ClassifiedListingSale.title LIKE '$formated_thesaurus%'"; $sql_aux[] = "ClassifiedListingSale.title LIKE '%$formated_thesaurus'"; $sql_aux[] = "ClassifiedListingSale.title LIKE '%$formated_thesaurus%'"; } $sql_where_homes_sale[] = "(".(implode(" OR ", $sql_aux)).")"; /* If mysql can perform full text search with current keyword */ } else { $thesaurus = ($word_amount = count(explode(" ",$keyword)) == 2) ? str_replace(" ", "", $keyword) : false; unset($keyword_arr); foreach(explode(" ", $keyword) as $each_keyword) { $keyword_arr[] = $each_keyword."*"; $keyword_arr[] = Inflector::singularize($each_keyword); $keyword_arr[] = Inflector::pluralize($each_keyword); } $keyword_arr[] = $thesaurus; $formated_keywords = db_formatString(implode(" ",$keyword_arr)); $priority_sql = " MATCH (ClassifiedListingSale.title) AGAINST (".$formated_keywords." IN BOOLEAN MODE) as search_priority1"; $sql_where_homes_sale[] = " MATCH (ClassifiedListingSale.title, ClassifiedListingSale.summarydesc, ClassifiedListingSale.detaildesc) AGAINST (".$formated_keywords." IN BOOLEAN MODE)"; } } // ------------------------------------------- // Zip --------------------------------------- if ($zip) { $zip = str_replace("\\", "", $zip); $_GET["zip"] = $zip; $miles = str_replace("\\", "", $miles); $_GET["miles"] = $miles; if (ZIPCODE_PROXIMITY == "on") { if (zipproximity_getWhereZipCodeProximity($zip, $miles, $whereZipCodeProximity)) $sql_where_homes_sale[] = $whereZipCodeProximity; else $sql_where_homes_sale[] = "ClassifiedListingSale.zip_code = '".$zip."'"; } else { $sql_where_homes_sale[] = "ClassifiedListingSale.zip_code = '".$zip."'"; } } // ------------------------------------------- if ($sql_where_homes_sale) $where .= " ".implode(" AND ", $sql_where_homes_sale)." "; $order = ($formated_keywords) ? "ClassifiedListingSale.level DESC, search_priority1 DESC" : "ClassifiedListingSale.level DESC, ClassifiedListingSale.title, ClassifiedListingSale.id"; $return_columns = ($priority_sql) ? "ClassifiedListingSale.*, $priority_sql" : "ClassifiedListingSale.*"; $pageObj = new pageBrowsing("ClassifiedListingSale", $screen, 10, $order, "ClassifiedListingSale.title", $letter, $where, $return_columns, "ClassifiedListingSale"); $classifieds = $pageObj->retrievePage(); $paging_url = DEFAULT_URL."/homesforsaleresults.php"; // get URL - $_GET not sent in constructor because system structure exclude vars named screen and letter $urlQuery = new UrlQueryGenerator(); foreach ($_GET as $name => $value){ if ($name != "screen" && $name != "letter"){ $urlQuery->setParameter($name, $value); } } $url_search_params = $urlQuery->buildUrlQuery(false); // Letters Menu ------------------------------ $letters = $pageObj->getString("letters"); foreach($letters as $each_letter) { if($each_letter == "#") $letters_menu .= "".strtoupper($each_letter).""; else $letters_menu .= "".strtoupper($each_letter).""; } // ------------------------------------------- # PAGES DROP DOWN ---------------------------------------------------------------------------------------------- $pagesDropDown = $pageObj->getPagesDropDown($_GET, $paging_url, $screen, "Go to page: ", "this.form.submit();"); # -------------------------------------------------------------------------------------------------------------- # ---------------------------------------------------------------------------------------------------- # HEADER # ---------------------------------------------------------------------------------------------------- $extrastyle = array(DEFAULT_URL."/layout/classified_result.css", DEFAULT_URL."/layout/classified_color.css", DEFAULT_URL."/layout/classified_front.css"); $banner_section = "classified"; include(EDIRECTORY_ROOT."/layout/header.php"); ?>
55+ Homes



55 Retirement Communities

Homes for Sale
getString("name"); } if($region_id){ $locationRegion = new LocationRegion($region_id); } ?> 55 Homes for Sale */?> 55+ Homes for Sale - () */?>

55+ Homes for Sale -

55 For Sale */ ?>

55+ Homes for Sale

content; } else{ $contentObj = new Content(); //$content = $contentObj->retrieveContentByType("Classified Results"); $content = $contentObj->retrieveContentByURL($state_title_a."_sale_content"); if(!$content){$content = $contentObj->retrieveContentByType("Classified Results");} } if ($content) { echo "
".$content."
"; } include("homesforsalecategories.php"); if (!$classifieds) { $db = db_getDBObject(); if($db->getRowCount("ClassifiedListingSale") > 0){ ?>

No results were found for the search criteria you requested.
Please try your search again.

Go back to the home page*/ ?>

No homes for sale registered yet.

Go back to the home page*/ ?> getNumber("level").".inc"); } include(INCLUDES_DIR."/tables/table_paging.inc"); } ?>


Advertisers