[sr_search_form] – Let users search for listings on your site

The [sr_search_form] short-code let’s you add a search form to any page on your website for your users to search and find MLS listings. This short-code is mostly commonly used with the [sr_listings] to tie together the behavior of searching and viewing listings.

When this short-code is used, a search form will be added to the page like the example below. You can set default search parameters and restrictions on the search form, while the user can modify (some) search parameters and navigate results.


This short-code can be used on any page, post, and anywhere else short-codes are allowed in WordPress.

Basic syntax:


With options and filters:

[sr_search_form type="Rental" maxprice="2500"]


This takes some options described to modify the output and behavior of the search form. Most of the useful options for this short-code are the search filters that control what listings the user sees in their results.

advancedfalseShow an advanced search form with more filtering options.[sr_search_form advanced="true"]

Search filters

Search filters give you a way to set pre-defined search criteria for users searching for listings on your site. For example, you can use the brokers filter to create a search form that searches your offices listings, or the minprice/maxprice filters to set initial values on the form.

vendornullfalseThe RETS vendor to search (required with multi-mls accounts).vendor="har"
limit20falseThe number of results per page (max 500) after the user submits the form.limit="500"
brokersnulltrueFilter listings by broker MLS ID(s).brokers="office1; office2"
agentnulltrueFilter listings by agent MLS ID(s).agent="agent1; agent2"
waternullFilter listings by a waterfront (or “true” for all waterfront listings).water="Lake Name"
Residential; RentalfalseFilter listings by property type.type="Condominium"
subtypenulltrueFilter listings by property subtype.subtype="Townhouse; ManufacturedHome"
countiesnulltrueFilter listings by counties.counties="Harris; Montgomery"
postalCoddesnulltrueFilter listings by zip codes.postalCodes="77001; 77002"
neighborhoodsnulltrueFilter listings by neighborhoods.neighborhoods="Garden Oaks; Towne Lake"
citiesnulltrueFilter listings by cities.cities="Houston; Chicago"
sortModifed, descendingfalseSort the listings on list date, price , # of bedrooms, or # of bathrooms.sort="-listdate"
qnullfalseA textual keyword search. Note: This populates the “keyword”.q="Houston"
statusActive; PendingtrueFilter listings by status.status="Active; Closed"
minpricenullfalseFilter listings by a minimum price.minprice="500000"
maxpricenullfalseFilter listings by a maximum price.maxprice="1000000"
minbedsnullfalseFilter listings by a minimum number of bedrooms.minbeds="3"
maxbedsnullfalseFilter listings a maximum number of bedrooms.maxbeds="5"
minbathsnullfalseFilter listings by a minimum number of bathrooms.minbaths="2"
maxbathsnullfalseFilter listings by a maximum number of bathroroms.maxbaths="5"


The example below shows a basic search form with initial values for the minprice/maxprice options. The user can change these values and re-submit the form, try it below:

Raw short-code:

[sr_search_form minprice="100000" maxprice="500000"]


Search Listings

Example 2 (advanced search form)

This example demonstrates the advanced search form, which gives your users more options for finding listings on your website. (Note: some of the options below will populate with data from your MLS).

Raw short-code:

[sr_search_form advanced="true"]


Close Menu