Hi there - Just trying to create a new construction snippet so I can have a page that pulls only new construction. Can you check out my code below? Note...I do not want to use minimum/maximum year because I don't want to have to edit each year.
Please advise.
- Florence
<?php
/* Snippet Settings */
$_REQUEST['snippet_title'] = 'Search Results';
$_REQUEST['snippet_price_table'] = true;
/* Search City */
$_REQUEST['search_city'][] = 'New Bern';
//$_REQUEST['search_city'][] = 'Oriental';
/* Search Area */
//$_REQUEST['search_area'][] = 'area';
/* Search Subdivision */
//$_REQUEST['search_subdivision'][] = 'subdivision';
/* Search Zip Code */
//$_REQUEST['search_zip'][] = '';
/* Search by MLS Number */
//$_REQUEST['search_mls'][] = '';
/* Search by Type */
//$_REQUEST['search_type'][] = 'type';
/* Search by New Construction */
$_REQUEST['search_new_construction'] = 'Y';
Or
$_REQUEST['search_new_construction'] = 'N';
/* Property Type */
$_REQUEST['idx'] = 'residential'; // Residential
//$_REQUEST['idx'] = 'land-and-lots'; // Land & Lots
//$_REQUEST['idx'] = 'commercial-sales'; // Commercial Sales
//$_REQUEST['idx'] = 'commercial-lease'; // Commercial Lease
//$_REQUEST['idx'] = 'boat-slips'; // Boat Slips
//$_REQUEST['idx'] = 'rentals'; // Rentals
/* Price Range */
$_REQUEST['minimum_price'] = 0;
$_REQUEST['maximum_price'] = 5000000;
/* Bedrooms */
//$_REQUEST['minimum_bedrooms'] = 0;
//$_REQUEST['maximum_bedrooms'] = 0;
/* Bathrooms */
//$_REQUEST['minimum_bathrooms'] = 0;
//$_REQUEST['maximum_bathrooms'] = 0;
/* Square Feet */
//$_REQUEST['minimum_sqft'] = 0;
//$_REQUEST['maximum_sqft'] = 0;
/* Year Built */
//$_REQUEST['minimum_year'] = 0;
//$_REQUEST['maximum_year'] = 0;
/* Acres */
//$_REQUEST['minimum_acres'] = 0;
//$_REQUEST['maximum_acres'] = 0;
/* Search Remarks */
//$_REQUEST['search_remarks'] = 'remarks';
/* Only this agent's listings */
$_REQUEST['agent_id'] = '';
/* Only this office's listings */
$_REQUEST['office_id'] = '';
/* Page Limit */
$_REQUEST['page_limit'] = 12;
/** DO NOT EDIT BELOW THIS LINE **/
$_REQUEST['snippet'] = true;
include $_SERVER['DOCUMENT_ROOT'] . '/idx/common.inc.php';
include_once $_SERVER['DOCUMENT_ROOT'] . '/idx/inc/php/pages/search.php';
?>

Reply With Quote
