1. Home
  2. Docs
  3. Places
  4. Places Settings – Sorting

Places Settings – Sorting


Introduction
Settings
Support
FAQ – Frequently Asked Questions

Introduction

Sorting applies to listings shown on the Archive template using the gd_loop element. An example of an Archive page is /places/, which will show all the listings that are gd_places.

Each CPT can have independent sorting options. You might want to sort paid listings by “Featured” and then sort events by Date, for example.

Sorting features do not apply to search results. Search results are always sorted by relevance.

Find the Places Settings – Sorting (tab) in the backend.

Default Settings

Setting Up a Sub-Sort Order

Where results are ‘equal’ within the sort, they can be sorted again. For example, the first sort is by Title (alpha), then within all the listings starting with “A”, sort them again by which are highest rated.

You can set this ‘sub-sort’ up like so:

gd_loop_actions

Use gd_loop_actions in a GD Archive template to display sorting and layout options.

Hide the layout dropdown with Custom CSS:

.geodir-list-view-select {
    display: none;
}

gd_loop_actions

Use gd_loop_actions in a GD Archive template to display sorting and layout options.

Hide the layout dropdown with Custom CSS:

.geodir-list-view-select {
    display: none;
}

gd_loop_paging

Use gd_loop_paging in a GD Archive template to display paging links.

You can add gd_loop_paging above, below, or above and below.

To remove paging, simply remove gd_loop_paging from the template.

Featured first in Archive pages

gd_loop uses the configuration in the “Sorting” tab to sort listings.

To show Featured listings first, put the following configuration in place:

  1. Add the Featured field to the Custom Post Type – Read more
  2. Open the Sorting tab.
  3. Click “Is Featured” on the left to add it to the sorting options on the right.
  4. Change the label – In the image we show changing it from “Is Featured” to “Recommended”.
  5. Set as the Default Sort” – when GD Loop loads, it will display the Default sort automatically.
  6. Set as active – make the sort active.
  7. Optional – Add a sub-sort by Title (A-Z) or Add Date (Descending (Latest)) to sort the featured listings into a sub-order.

Read more about the Featured Field or how to decorate Featured Listings.

Get Support

Get support on our forum, fnd out more here: https://wpgeodirectory.com/docs-v2/v2/support/

FAQ – Frequently Asked Questions

How can I make Featured listings first on the search page?

The sorting options control the default sort of the listings that appear on the Archive pages. Search results are sorted by relevance and do not have sorting options.

Was this article helpful to you? Yes No